I have piece of html code in php $string . The problem is, I need to remove all "img" and "a href" tags from it. I guess I should use preg_replace function, but how should my patterns look like?
I would like to replace:
"<img some params and address>" with ""
and
"<a href="some random address with unknown length">my text</a>" with "my text"