{$eyou.field.typeid|GetTotalArc=###}当前 {$eyou.field.typeid=1|GetTotalArc=###}指定ID
{eyou:type type='self'} {$field.id|gettoptype=###,typename} {/eyou:type}
{$eyou.field.content}
{eyou:channel type="son" currentstyle="active"} <a href="{$field.typeurl}" title="{$field.typename}" class="{$field.currentstyle}">{$field.typename}</a> {/eyou:channel}
{eyou:channel type="self" currentstyle="active"} <a href="{$field.typeurl}" title="{$field.typename}" class="{$field.currentstyle}">{$field.typename}</a> {/eyou:channel}
{eyou:list pagesize='20' titlelen='40'} {eyou:eq name='$i' value='1'}<!--判断开始--> <li>img src="{$field.litpic}"><a href="{$field.arcurl}" title="{$field.title}">{$field.title}</a</li><!--第一条--> {else /}<!--判断第一条结束--> <li><a href="{$field.arcurl}" title="{$field.title}">{$field.title}</a></li><!--余下条数--> {/eyou:eq}<!--判断结束--> {/eyou:list}
{eyou:gt name="$eyou.field.has_children" value="0"}有则显示{/eyou:gt}
gt 大于 greater than
{$eyou.field.typeid|GetTotalArc=###}
统计栏目文章数 — GetTotalArc(当前栏目ID)
{eyou:channel type="first" currentstyle="active"} {eyou:eq name='$eyou.field.grade' value='2'} {eyou:type typeid='$eyou.field.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> <a href="{$field.typeurl}" class="{$field.currentstyle}">{$field.typename}</a> </li> {/eyou:channel} ---------------------------------------------------------- {eyou:channel type='sonself' currentstyle="active"} <li> <a href="{$field.typeurl}" title="{$field.typename}" class="{$field.currentstyle}">{$field.typename}</a> </li> {/eyou:channel}
{eyou:list} {eyou:eq name='$field.is_recom' value='1'} <span>{$field.is_recom}</span> {/eyou:eq} {/eyou:list}
推荐:is_recom
特荐:is_special
头条:is_head
<!--标签页seo标题--> <title>{$eyou.field.seo_title}_标签页_{eyou:global name="web_name" /}</title> <!--标签页seo描述--> <meta name="description" content="{$eyou.field.seo_description}" /> <!--标签页seo关键词--> <meta name="keywords" content="{$eyou.field.seo_keywords}" />
{$field.downcount}
<!-- 收藏代码开始 --> <a href="javascript:void(0);" id="ey_1595557091" onclick="ey_1595557091(this);" data-html="已收藏">加入收藏</a> {:hookexec('Collection/Collection/show')} <!-- 收藏代码结束 -->
需要购买插件
{eyou:memberinfos mid='$field.users_id' id='users'} <img src="{$users.head_pic}" class="radius-big ans-user-head float-left" alt="{$users.nickname}"> {$users.hidden} {/eyou:memberinfos}
{eyou:sppurchase id='field' currentstyle='btn-danger'} <a class="" href="JavaScript:void(0);" {$field.ShopAddCart}>加入购物车(或者图文字体)</a> {$field.hidden} {/eyou:sppurchase}
<!-- 分类折叠手风琴菜单 开始 --> <div class="subnavbox bg-white radius"> <h2 class="bg-blue text-white">{eyou:channelartlist typeid='$eyou.field.typeid|gettoptype=###,typeid'}{eyou:field name='typename' /}{/eyou:channelartlist}</h2> <!--当前栏目下二级栏目调用--> {eyou:channel type="first" currentstyle="active"} {eyou:eq name='$eyou.field.grade' value='2'} {eyou:type typeid='$eyou.field.typeid' id='field1'} {eyou:eq name='$field1.parent_id' value='$field.id'} {eyou:assign name='$field.currentstyle' value='current' /} <!--current对应样式中的display:block--> {/eyou:eq} {/eyou:type} {/eyou:eq} <div class="{$field.currentstyle}dd {$field.currentstyle}dt suboneNav">{$field.typename}</div> <!--当前栏目下三级栏目调用--> {eyou:notempty name="$field.children"} <ul class="cur-bg {$field.currentstyle}"> {eyou:channel name="$field.children" id="field2"} <li><a href="{$field2.typeurl}" class="{$field2.currentstyle}">{$field2.typename}{$field2.typeid}</a> </li> {/eyou:channel} </ul> {/eyou:notempty} {/eyou:channel} </div> <!-- 分类折叠手风琴菜单 结束 -->
CSS和JS代码可以点此链接获取:https://www.tbadc.com/coding/559.html
<!-- 一级栏目名称 --> <h1>{eyou:channelartlist typeid='$eyou.field.typeid|gettoptype=###,typeid'}{eyou:field name='typename' /}{/eyou:channelartlist}</h1> <!--二级栏目开始--> {eyou:channel type="first" currentstyle="active"} {eyou:eq name='$eyou.field.grade' value='2'} {eyou:type typeid='$eyou.field.typeid' id='field1'} {eyou:eq name='$field1.parent_id' value='$field.id'} {eyou:assign name='$field.currentstyle' value='current' /} <!--current对应样式中的display:block--> {/eyou:eq} {/eyou:type} {/eyou:eq} <h2 class="{$field.currentstyle}">{$field.typename}</h2><!-- 二级栏目名称 --> <!--三级栏目开始--> {eyou:notempty name="$field.children"} {eyou:channel name="$field.children" id="field2"} <h3><a href="{$field2.typeurl}" class="{$field2.currentstyle}">{$field2.typename}{$field2.typeid}<!-- 三级栏目名称 --></a></h3> {/eyou:channel} {/eyou:notempty} {/eyou:channel}
可以参考https://www.feikoo.com/xingyedongtai/204.html做手风琴折叠菜单
<a href="{$eyou.field.typeid|gettoptype=###,'typeurl'}" title="{$eyou.field.typeid|gettoptype=###,'typename'}" {eyou:eq name='$eyou.field.typeid' value='$eyou.field.typeid|gettoptype=###,typeid'}class="active"{/eyou:eq}> 全部 </a>
https://www.tbadc.com/coding/
<a href="{$eyou.field.typeid|gettoptype=###,'typeurl'}"> {$eyou.field.typeid|gettoptype=###,'typename'} </a>
顶级栏目图片: “{$eyou.field.typeid|gettoptype=###,'litpic'}“
<a href="{$eyou.field.ptypeurl}">{$eyou.field.ptypename}</a>
上级栏目ID:{$eyou.field.ptypeid}
上级栏目链接:{$eyou.field.ptypeurl}
上级栏目名称:{$eyou.field.ptypename}
type="self" self表示同级
<a href="{$eyou.field.typeurl}">{$eyou.field.typename}</a>
{eyou:memberinfos mid='$field.users_id' id='users'} 会员昵称:{$users.nickname} 会员头像:<img src="{$users.head_pic}" width='50' height='50' /> {$users.hidden} {/eyou:memberinfos}
适用1.47+版本
{eyou:list} <a href="{$field.arcurl}">{$field.title}</a> {eyou:arcview aid='$field.aid' id='view'} {eyou:volist name="$view.file_list" id='vo'} <a href="{$vo.downurl}" title="{$vo.title}">下载</a> {/eyou:volist} {/eyou:arcview} {/eyou:list}
arclist与list都可以
{eyou:list pagesize='12' id='field'} {eyou:arcview id='field2'} {eyou:volist name="$field2.image_list" id='field3'} <img src="{$field3.image_url}" alt="{$field3.intro}"> {/eyou:volist} {/eyou:arcview} {/eyou:list}
{eyou:list} 标题:{$field.title} 阅读数:{$field.click} 标签:{eyou:tag sort='now' getall='0' row='10' id='field2'} <a href='{$field2.link}' class="tag">{$field2.tag</a>{/eyou:tag} {/eyou:list}
关注是要注意id='field2',也可用于arclist指定ID,如:
{eyou:arclist row='5' titlelen='80' }{eyou:tag sort='now' getall='0' row='10' id='field2'}<a href='{$field2.link}'>{$field2.tag}</a>{/eyou:tag}{/eyou:arclist}
sort='' 标签排序方式
sort='new' 按最新排序
sort='rand' 随机排序
sort='week' 按周统计排序
sort='month' 按月统计排序
sort='hot' 按点击数排序
sort='total' 按文档数排序
{eyou:tag getall='1' row='50' sort='hot'} <a href='{$field.link}'>{$field.tag}</a> {/eyou:tag}
getall='' 获取类型,0为当前内容页TAG标记,1为获取全部TAG标记
{eyou:arclist addfields='content' } <span>{$field.content}</span> {/eyou:arclist}
addfields='content' 为调取文章内容的标签属性,必加在arclist里
{$field.content} 为调取文章内容不过滤样式的标签。
{$field.content|html_msubstr=###} 为调取文章内容过滤样式的标签。
{$field.content|html_msubstr=###,0,155} 为调取文章内容过滤样式并截取155个字符的标签。
{$field.seo_description}
{eyou:eq name='$field.is_litpic' value='1'} <img src="{$field.litpic}"> {/eyou:eq}
可以放在list和arclist文档列表内,可以结合{eyou:else/}