I have a question about parsing text and removing unwanted html parts.
I know functions like – strip_tags() which will remove all the tags, but the problem is, that this function leaves the “inside text” there.
Let me show you an example, we have a text:
Hello, how are you? <a href="">Link to my website</a> __Here continues html tags, links, images__
What I want is to remove the whole part, where html resides. Not only tags, but also text (like “Link to my website” above).
Is there any efficient way, function that I missed?
Try this:
Output: