Home > Article > Backend Development > How to convert text with html tags into plain text in php
Tag phphtml
Such as the following text
preg_replace regular replacement
http://www.jb51.net/article/27706.htm
<code> <?php $s="<a>aaaa<b>bbbbb</b><font color="red">cc</font>"; echo $s."<br>"; $s= preg_replace("/]+>/is", "", $s); echo $s; ?> </code>