带有二级子栏目的栏目的调用,这类网站用于信息分类比较多的网站,其样式图如下:

 

  这种栏目是比较常见的,其dedecms调用代码如下:

{dede:channelartlist typeid='1,2,3,6,7,10,8,11' row='10'}    //typeid=‘顶级栏目的id’

  {dede:field name='typename'/}

     {dede:channel type='son' noself='yes'}

    [field:typename/]

 {/dede:channel}

  {/dede:channelartlist}

 添加样式

  {dede:channelartlist type='top' row='8'} 
      <ul class="nav navbar-nav">
        <li class="dropdown">
          <a href="" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">{dede:field name='typename'/} </a>
            <ul class="dropdown-menu">
           {dede:channel type='son' noself='yes'}
            <li><a href="[field:typelink/]">[field:typename/]</a></li>
           {/dede:channel}
            </ul>
        </li>
      </ul>
    {/dede:channelartlist}

 幻灯

      {dede:arclist flag='f' row='5'}

        [field:global name=autoindex runphp="yes"]
        if(@me == 1)
        @me='<div class="item active">  ';
        else @me = '<div class="item">  ';

        [/field:global]

        <img src="[field:litpic/]">
        <div class="carousel-caption">
        "[field:title function='html2text(@me)'/]"
        </div>
      </div>
      {/dede:arclist}

 

posted on 2015-09-06 11:57  jzfan  阅读(260)  评论(0编辑  收藏  举报