您的位置:首页 > 帮助 > 标签手册 > 子栏目及列表循环调用
子栏目及列表循环调用
发布时间:2022-11-07    编辑:admin    浏览次数:2235 次    [   ]

{leaf:nav parent_id=2 }{leaf.nav.name}<ul>{leaf:list catid=$nav[id] num=6 }&n
{leaf:nav parent_id=2 }
    {leaf.nav.name}
    <ul>
        {leaf:list catid=$nav[id] num=6 }
        <li>
            <a href="{leaf.list.url}">{leaf.list.title}</a>
        </li>
        {/leaf:list}
    </ul>
{/leaf:nav}
{leaf:nav num=7}
<a href="{leaf.nav.url}">{leaf.nav.name}</a>
    {leaf:if $nav[child]}
    {leaf:nav parent_id=$nav[id] r=nav2}
    <a href="{leaf.nav2.url}">{leaf.nav2.name}</a>
        {leaf:if $nav[child]}
        {leaf:nav parent_id=$nav2[id] r=nav3}
        <a href="{leaf.nav3.url}">{leaf.nav3.name}</a>
        {/leaf:nav}
        {/leaf:if}
    {/leaf:nav}
    {/leaf:if}        
{/leaf:nav}


嘿,我来帮您!