我想問下,如何在單頁中顯示一級菜單下的二級菜單
如圖
我使用了欄目列表循環(huán),結(jié)果報錯 http://m.apdwn.com/doc/388.html http://m.apdwn.com/doc/389.html
{category module=share id=2}
<dd class="web__page-aside-dd">
<a class="web__page-aside-dd-a d-flex justify-content-between align-items-center" href="{$t.url}" title="{$t.name}"
target="_blank">
<span class="web__page-aside-dd-a-span">{$t.name}</span>
<i class="iconfont icon-you web__page-aside-dd-a-icon"></i>
</a>
</dd>
{/category}官方提醒:使用category欄目循環(huán)標(biāo)簽的生成工具,填寫參數(shù)就可以生成相關(guān)的代碼,每個參數(shù)后面都有用法解釋
查到了解決辦法了
{category module=MOD_DIR pid=2 return=c} <dd class="web__page-aside-dd"> <a class="web__page-aside-dd-a d-flex justify-content-between align-items-center {if $c.id==$catid}active{/if}" href="{$c.url}" title="{$c.name}" target="_blank"> <span class="web__page-aside-dd-a-span">{$c.name}</span> <i class="iconfont icon-you web__page-aside-dd-a-icon"></i> </a> </dd> {/category}