织梦dedecms栏目内容自动标签的方法,处理写法如下: {dede:field.content runphp=yes} $str = preg_replace(/^s+/, , html2text(@me)); if( !empty($str) ){ @me = div class=content.@me./div; }else{ @me = ; } {/dede:field.content
-
{dede:field.content runphp="yes"} $str = preg_replace("/^s+/", "", html2text(@me)); if( !empty($str) ){ @me = '<div class="content">'.@me.'</div>'; }else{ @me = ''; } {/dede:field.content}