oohoohoohooh
Programmer
Hi, I was wondering how you strip the contents of a string uptil the first occurance of <a and also how to strip a string to the last occurance of </a>
ie
$string = '<body>
<a href="test.htm">test</a>
<a href="text2.htm">test2</a>
</body>';
will return:
$string = '<a href="test.htm">test</a>
<a href="text2.htm">test2</a>';
Appreciate it if someone could help. Thanks
ie
$string = '<body>
<a href="test.htm">test</a>
<a href="text2.htm">test2</a>
</body>';
will return:
$string = '<a href="test.htm">test</a>
<a href="text2.htm">test2</a>';
Appreciate it if someone could help. Thanks