I have a regex I'm trying to get out of a string. It seems to be including way too much. Here's my code.
preg_match_all('/<li class="has-activity"><a class="group-entity"
href="(.*?)"><span class="activity-count">(.*)<\/span><span
class="image"><img alt="(.*?)" src/i',$output,$matches);
I JUST want it to grab the stuff as seen in (.*?) , but it seems to want to grab more.
MORE INFO:
Here's an example of what I'm trying to extract from. This is just one entity though. (Using preg_match_all)
<li class="has-activity"><a class="group-entity" href="/grp/home?gid=2813868&trk=my_groups-tile-grp">
<span class="activity-count">7</span>
<span class="image"><img alt="[Rated #1 in Marketing] The Social Media Marketing Group" src
The two main things I need to grab is the group href ("/grp/home?gid=2813868&trk=my_groups-tile-grp" in this instance) and the group name (the thing between the alt tag. "[Rated #1 in Marketing] The Social Media Marketing Group" in this case)
With my updated code of (.?*), it seems to be grabbing the NAME just fine. But I can't properly grab the href of the group.