XML/HTML代码
- /**
- * 过滤掉回车...
- */
- function cut_br($content,$replace=''){
- while(ereg(chr(10),$content)) {
- $tmp1=substr($content,0,(strpos($content,chr(10))-1)).$replace;
- $tmp2=substr($content,(strpos($content,chr(10))+1));
- $content=$tmp1.$tmp2;
- }
- if(strlen($content) > 40) $content = str_replace(' ','',$content);
- return $content;
- }