Hi,
I have a string of markup where I’ve got links pointing to relative locations rather than absolute locations. ie, the anchor tags have:
...href="/SomeDir"...
...href="/AnotherDir"...
...href="/YetAnotherDir"...
What I’d like to do is scan the markup and gather all the directory names into an array. I don’t need anything but the textual names. However, I also have some links that contain multiple forward-slashes, and these can be ignored. What I’m looking for in the end result is:
$array[0] = 'SomeDir';
$array[1] = 'AnotherDir';
$array[2] = 'YetAnotherDir';
I tried preg_match_all quite a few times/ways before my eclipse crashed and left me with nothing to show for it. :\ So, rather than try to trial and error my way through again, I’m hoping someone can show me the light…
BTW, the search results page is white-screening!
Thanks,
cranjled