eyoucms三级分类折叠菜单输出和当前焦点标签

2020-05-19

eyoucms三级分类折叠菜单输出和当前焦点标签标签代码,请注意下面的field1和field2

{eyou:channel type="first" currentstyle="active"} 
      {eyou:eq name='$eyou.field.grade' value='2'} 
        {eyou:type typeid='$eyou.fielfd.typeid' id='field1'} 
          {eyou:eq name='$field1.parent_id' value='$field.id'} 
             {eyou:assign name='$field.currentstyle' value='active' /}
          {/eyou:eq} 
          {/eyou:type} 
       {/eyou:eq}
        <li class="clearfix">
          <a href="{$field.typeurl}" class="{$field.currentstyle}">{$field.typename}</a><!--二级分类-->
             {eyou:notempty name="$field.children"} 
               <ul>
                    {eyou:channel name="$field.children" id="field2" currentstyle="active"}
                      <li><a href="{$field2.typeurl}" class="{$field2.currentstyle}">{$field2.typename}</a></li><!--三级分类-->
                    {/eyou:channel}
                </ul>
          {/eyou:notempty}              
       </li>
 {/eyou:channel}


Tag: eyoucms标签