ppypp伦理天堂,91手机在线视频,免费在线观看黄色毛片,夜夜穞天天穞狠狠穞AV美女按摩

聯系官方銷售客服

1835022288

028-61286886

投訴 已解決 二級導航欄如何實現兩級選中 3 0
迅睿CMS版本:4.3.9

二級導航欄如何實現兩級選中 ?

{category module=share id=1,2,3 }
     <li><a href="{$t.url}"><button {if $cat.id == $t.id} class="active" {/if}>{$t.name}</button></a>
          {if $t.child}
           <div class="baikeList">
                {category module=share pid=$t.id return=c}
                <a href="{$c.url}" {if $c.id == $cat.id} class="active"{/if}>{$c.name}</a>
                {/category}
            </div>
           {/if}
      </li>
{/category}

目前只能實現 選中 當前 欄目ID 如何能實現選中兩級

官方提醒:使用category欄目循環標簽的生成工具,填寫參數就可以生成相關的代碼,每個參數后面都有用法解釋

解決方案
  • 寫法錯了,你參考默認模板header。html的寫法

    滿意答案
    短信幣+1
  • 感謝,大佬,解決問題

    {category module=share id=1,2,3 }
         <li><a  target="_blank" href="{$t.url}"><button {if IS_SHARE && $catid && in_array($catid, $t.catids)} class="active"{/if}>{$t.name}</button></a>
              {if $t.child}
               <div class="baikeList">
                    {category module=share pid=$t.id return=c}
                    <a  target="_blank" href="{$c.url}" {if $c.id == $cat.id} class="active"{/if}>{$c.name}</a>
                    {/category}
                </div>
               {/if}
          </li>
    {/category}
  • if $c.id == $cat.id} class="active"{/if}

    改成

    {if IS_SHARE && $catid && in_array($catid, $c.catids)} class="active"{/if}

    默認模板現成的寫法,哈哈

  • 迅睿框架創始人:已解決問題,已解決問題