PHP - Removing the effect of HTML tags in string - BUT displaying them as well?
- by wretrOvian
Hi.
Consider strip_tags() .
strip_tags("<b>TEXT</b>");
Output:
TEXT
But what if i want to nullify the effect of the tags but display them as well?
Output:
<b>TEXT</b>
Would i have to use preg_replace() ? Or is there a more elegant solution available?
Thanks :D