I have a very simple problem. I need to remove the whole
<td colspan="3" rowspan="1"> </td>
tag from html only when its empty (its not completely empty though, has some sort of whitespace). Tried to use:
$html = str_replace("<td colspan=\"3\" rowspan=\"1\"> </td>","",$html);
$html = str_replace("<td colspan=\"3\" rowspan=\"1\"> </td>","",$html);
with no success.
preg_replace("/<td[^>]*>[\s| ]*<\/td>/", '', $html);
didnt work either.
It should be a fairly simple solution, any suggestions?