这不是smarty的活了,干什么非要扔给smarty?想不明白.

解决方案 »

  1.   

    smarty 可以扩展,自己写一个 plugin 或者 function 来作吧,呵呵
      

  2.   

    扔给smarty我可以少写好多东西。扩展我不会写块插件,用其它的不是我想要的。
    主要是要把一段html代码也要包含进去。不然直接写一个普通的插件就行了。
      

  3.   

    smarty只是一个工具,是辅助的,程序员是活的。
      

  4.   

    同意yueliangdao0608((深圳PHPER,MSN:[email protected])) 的方法
    写个循环,自己找
      

  5.   

    <!--{funif mpopedomgroups=s_manage}-->
    <!--系统管理 Start-->
    <table border="0" cellpadding="0" cellspacing="0" class="menuitemtb">
    <tr>
    <td class="menutitle" onclick="menucollpas('10')"><span class="menutitletext">系统管理</span><span class="menutitlecollpas" id="t10">展开<img src="images/icon_close.gif" border="0" align="absmiddle" /></span></td>
    </tr>
    <tr>
    <td class="menuitemtd" id="m10" style="display:none;">
    <ul>
    <!--{funif mpopedomgroups=s_manage mpopedom=admin_log}--><li><a href="###" target="mainframe">系统日志</a></li><!--{/funif}-->
    <!--{funif mpopedomgroups=s_manage mpopedom=db_manage}--><li><a href="###" target="mainframe">数据备份</a></li><!--{/funif}-->
    <!--{funif mpopedomgroups=s_manage mpopedom=sys_reset}--><li><a href="###" target="mainframe">恢复出厂配置</a></li><!--{/funif}-->
    </ul>
    </td>
    </tr>
    </table>
    <!--系统管理 End-->
    <!--{/funif}--> 
      

  6.   

    在php程序里in_array(),然后把返回值,
    $smarty->assign("signal",in_array("xiao",$str));我的小站也是用smarty写的,http://www.xiaoi8.com