How could I remove all the new lines from all img tags. So for instance if I have:
$string = '<img
src="somelong
pathimage.jpg"
height="1" width="10">';
so it looks as:
$string = '<img src="somelongpathimage.jpg" height="1" width="10">';
$string = preg_replace("/\n/" , "" , $string);