帝国CMS内容页模板过滤清理简介smalltext前后空格的方法!
2017-12-07 站长 站长日志
在内容模板你需要调用的地方使用如下代码输出简介即可过滤简介smalltext前后的空格了:
<?
$qian=array(" "," ","/t","/n","/r");$hou=array("","","","","");
$smalltext=str_replace($qian,$hou,$navinfor[smalltext]);
echo $smalltext;
?>
一个爱好网络的80后男站长。
关注我
2017-12-07 站长 站长日志
在内容模板你需要调用的地方使用如下代码输出简介即可过滤简介smalltext前后的空格了:
<?
$qian=array(" "," ","/t","/n","/r");$hou=array("","","","","");
$smalltext=str_replace($qian,$hou,$navinfor[smalltext]);
echo $smalltext;
?>