PHP开发实例大全(提高卷) 中文完整pdf扫描版[244MB]
                        php把html转换成文本text的函函
function Text2Html($txt){ 
 
		
		
        function Text2Html($txt){
        $txt = str_replace("  "," ",$txt);
        $txt = str_replace("<","<",$txt);  
        $txt = str_replace(">",">",$txt);
$txt = str_replace(",","",$txt);
$txt = str_replace(",","",$txt);
$txt = str_replace("“","",$txt);
$txt = str_replace("”","",$txt);
        $txt = preg_replace("/[rn]{1,}/isU","
rn",$txt);
        return $txt;
}
转载请注明:谷谷点程序 » php把html转换成文本text的函函