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

聯系官方銷售客服

1835022288

028-61286886

投訴 已解決 如何通過判斷導航欄目模型來調用欄目 9 0
迅睿CMS版本:4.5.1 懸賞:3元

如何通過判斷導航欄目模型來調用欄目

{category module=share pid=0 return=t1}
{if $t比如產品模型==1}

產品欄目

{elseif $t新聞模型==1}

新聞欄目

{else}

欄目

{/if}

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

解決方案
  • $t1.mid=="news"表示news模塊,以此類推

    滿意答案
    開源積分+10
    +3元
  • 回復@迅睿框架技術-李梧桐 同時間判斷2個模塊呢 news和product

  • 回復@迅睿框架技術-李梧桐 應該是我理解問題,可以把代碼貼出來么

  • {category module=share pid=0 return=t1}
    {if $t1.mid=="product"}
    產品欄目
    {elseif $t1.mid=="news"}
    新聞欄目
    {else}
    欄目
    {/if}
    {/category}

    套公式。。

  • 四樓代碼可可以

  • 回復@自學成才 是不是我代碼問題

            <ul class="clearfix">
                <li {if $indexc}class="cur" {/if}><a href="{SITE_URL}">首頁</a></li>{category module=share pid=0}
                <li {if IS_SHARE && $catid && dr_in_array($catid, $t.catids)}class="cur" {/if}>
                    <a href="{$t.url}">{$t.name}</a>
                    {if $t1.mid=="product"}
                    <div class="navbox">
                        <div class="container">
                            <h3>{$t.name}</h3>
                            <ol class="clearfix">
                                {category module=share pid=$t.id return=t2}
                                <li>
                                    <span><a href="{$t2.url}">{$t2.name}</a></span>{if $t2.child}
                                    <div>{category module=share pid=$t2.id return=t3}
                                        <a href="{$t3.url}" title="{$t3.name}">{/category}
                                    </div>{/if}
                                </li>{/category}
                            </ol>
                        </div>
                    </div>{elseif $t1.mid=="news"}
                    <div class="navbox navbox2">
                        <div class="container clearfix">
                            <div class="left">
                                <h3>{$t.name}</h3>
                                <ol class="clearfix">{category module=share pid=$t.id return=t2}
                                    <li>
                                        <span><a href="{$t2.url}">{$t2.name}</a></span>{if $t2.child}
                                        <div>{category module=share pid=$t2.id return=t3}
                                            <a href="{$t3.url}" title="{$t3.name}">{/category}
                                        </div>{/if}
                                    </li>{/category}
                                </ol>
                            </div>
                            <div class="right">
                                <img src="#" alt="專業技術團隊" />
                                <p>專業技術團隊</p>
                            </div>
                        </div>
                    </div>{else}
                    <div class="navbox navbox2 navbox3">
                        <div class="container clearfix">
                            <div class="left">
                                <h3>{$t.name}</h3>
                                <ol class="clearfix">
                                    {category module=share pid=$t.id return=t4}
                                    <li>
                                        <span><a href="{$t4.url}" title="{$t4.name}"></span>
                                    </li>{/category}
                                </ol>
                            </div>
                            <div class="right">
                                <img src="picture/navbox3.jpg" alt="LED應用領域的創新者" />
                                <p>LED應用領域的創新者</p>
                            </div>
                        </div>
                    </div>
                    {/if}
                </li>{/category}
            </ul>


  • 肯定有問題啊,上面都是$t.,你這里弄一個$t1,t1是哪里來的。。。。

    QQ2065367601-
  • 回復@疾風 這個剛發得時候就看見了,還是有些問題

  • @迅睿框架技術-李梧桐:已經解決了