How to remove first link with image from this text with PHP?
<a href="some link"><img src="image link" /></a>Lorem ipsum dolor sit amet, consectetur adipiscing elit.**
How to remove first link with image from this text with PHP?
<a href="some link"><img src="image link" /></a>Lorem ipsum dolor sit amet, consectetur adipiscing elit.**
I would start by splitting the line by the '>' character..
PHP:
$line = "<a href=''><img src=''></a>blah blah blah";
$parts = explode('>', $line);
If you wanted the image....
$img = $parts[1].">";
If you want just the text...
$text = $parts[3];