问答

导航内用if判断栏目id,显示错误的标签变量名

2018-09-15
一、导航内用if判断栏目id使用了两种写法:
1、<ul class="nav nav-menu nav-inline nav-pills text-right">
            <li  class='active'><a href="/" class="topa"> 首页</a></li>
            {eyou:channel type="top" row="60" id="field" currentstyle="active"}
            <li class=''><a href="{$field.typeurl}" class="topa">{$field.typename}</a>
              {eyou:if condition='($eyou.field.typeid == "4")'}
                111       
              {/eyou:if}
            {eyou:notempty name="$field.children"}
              <ul class="drop-menu"
                > 
                {eyou:channel name="$field.children" row="100" id="field2"}
                <li><a href="{$field2.typeurl}">{$field2.typename}</a></li>
                {/eyou:channel}               
              </ul>
            {/eyou:notempty}
            </li>
            {/eyou:channel}
          </ul> 
2、<ul class="nav nav-menu nav-inline nav-pills text-right">
            <li  class='active'><a href="/" class="topa"> 首页</a></li>
            {eyou:channel type="top" row="60" id="field" currentstyle="active"}
            <li class=''><a href="{$field.typeurl}" class="topa" >{$field.typename}</a>
              {eyou:eq name='$eyou.field.typeid' value='4'}
                111
              {/eyou:eq}
            {eyou:notempty name="$field.children"}
              <ul class="drop-menu"
                > 
                {eyou:channel name="$field.children" row="100" id="field2"}
                <li><a href="{$field2.typeurl}">{$field2.typename}</a></li>
                {/eyou:channel}               
              </ul>
            {/eyou:notempty}
            </li>
            {/eyou:channel}
          </ul>
均报错显示:

未定义数组索引,错误的标签变量名: field

二、按照手册上查询单条文档数据:
{eyou:arcview aid='43'}
<a href="{$field.arcurl}">{$field.title}</a>
{/eyou:arcview}
报错显示:

未定义数组索引,错误的标签变量名: arcurl

三、关于图集模型
1、使用{$eyou.field.content}调用文章详细内容,无论内容为粘贴还是手动输入,前台页面均显示代码格式,例:<p>111111111111111111111</p>
2、如何调用封面图片

问题很多,麻烦了。
QQ在线咨询