function html2txt($document){
$search = array('@@si', // Strip out javascript
'@@siU', // Strip style tags properly
'@<[/!]*?[^<>]*?>@si', // Strip out HTML tags
'@@' // Strip multi-line comments including CDATA
);
$text = preg_replace($search, '', $document);
return $text;
}
33朵
0个