$str = trim($str)
$str = preg_replace("</P>","1234a3211",$str)
$str = preg_replace("</p>","1234a3211",$str)
$str = preg_replace("<br/>","1234a3211",$str)
$str = preg_replace("/<(.[^>]*)>/","",$str)
$str = preg_replace("/([\r\n])[\s]+/","",$str)
$str = preg_replace("/-->/","",$str)
$str = preg_replace("/<!--.*/","",$str)
$str = preg_replace("/&(quot|#34)/","",$str)
$str = preg_replace("/&(amp|#38)/", "/&/",$str)
$str = preg_replace("/&(lt|#60)/", "/</",$str)
$str = preg_replace("/&(gt|#62)/", ">",$str)
$str = preg_replace("/&(nbsp|#160)/", "",$str)
$str = preg_replace("/&(iexcl|#161)/", "/\xa1/",$str)
$str = preg_replace("/&(cent|#162)/", "/\xa2/",$str)
$str = preg_replace("/&(pound|#163)/", "/\xa3/",$str)
$str = preg_replace("/&(copy|#169)/", "/\xa9/",$str)
$str = preg_replace("/(\d+)/", "",$str)
$str = preg_replace("/</", "",$str)
$str = preg_replace("/>/", "",$str)
$str = preg_replace("/\r\n/", "",$str)
$str = preg_replace("/1234a3211/", "/<br/>/",$str)
return $str
}
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)