phpcms之调用导航栏

首页:{pc:content action= "category " catid= "0 " num= "25 " siteid= "$siteid " order= "lis

首页:

{pc:content action="category" catid="0" num="25" siteid="$siteid" order="listorder ASC"}
            <ul id="header-menu" class="menu">
                {if $top_parentid == 0}
                <li class="hover"><a href="{siteurl($siteid)}">首页</a></li>
                {else}
                <li><a href="{siteurl($siteid)}">首页</a></li>
                {/if}
                {loop $data $r}
                {if $catid == $r[catid] || $top_parentid == $r[catid]}
                <li class="hover"><a href="{$r[url]}">{$r[catname]}</a></li>
                {else}
                <li><a href="{$r[url]}">{$r[catname]}</a></li>
                {/if}
                {/loop}
            </ul>
            {/pc}

单页面:

  

{pc:content action="category" catid="0" num="25" siteid="$siteid" order="listorder ASC"}
            <ul id="header-menu" class="menu">
                {if $top_parentid == 0}
                <li class="hover"><a href="{siteurl($siteid)}">首页</a></li>
                {else}
                <li><a href="{siteurl($siteid)}">首页</a></li>
                {/if}
                {loop $data $r}
                {if $catid == $r[catid] || $top_parentid == $r[catid]}
                <li class="hover"><a href="{$r[url]}">{$r[catname]}</a></li>
                {else}
                <li><a href="{$r[url]}">{$r[catname]}</a></li>
                {/if}
                {/loop}
            </ul>
            {/pc}

 

{pc:content action="category" catid="0" num="25" siteid="$siteid" order="listorder ASC"}

               <ul id="header-menu" class="menu">

                      {if $top_parentid == 0}

                      <li class="hover"><a href="{siteurl($siteid)}">首页</a></li>

                      {else}

                      <li><a href="{siteurl($siteid)}">首页</a></li>

                      {/if}

                      {loop $data $r}

                      {if $catid == $r[catid] || $top_parentid == $r[catid]}

                      <li class="hover"><a href="{$r[url]}">{$r[catname]}</a></li>

                      {else}

                      <li><a href="{$r[url]}">{$r[catname]}</a></li>

                      {/if}

                      {/loop}

               </ul>

               {/pc}

标签: 首页