获取专题列表。
com.jspxcms.core.web.directive.SpecialListDirective
com.jspxcms.core.web.directive.SpecialPageDirective
'1,2,5'
。默认为当前站点,如果要获取所有站点的数据,可以传空字符串''
。'1,2,5'
。.now
,'2012-06-03'
,'2000-10-18T23:45:09'
。.now
,'2012-06-03'
,'2000-10-18T23:45:09'
。'true'
,'false'
。'true'
,'false'
。获取当前站点的所有专题列表:
[@SpecialList limit='8';list]
[#list list as special]
<a href="${ctx}/special/${special.id}">${special.title}</a>
[/#list]
[/@SpecialList]
获取当前专题类别的所有专题列表(本例在专题类别页中使用,专题类别页有默认的专题类别对象category
):
[@SpecialList categoryId=category.id limit='8';list]
[#list list as special]
<a href="${ctx}/special/${special.id}">${special.title}</a>
[/#list]
[/@SpecialList]
分页标签示例:
[@SpecialPage categoryId=category.id pageSize='20';pagedList]
[#list pagedList.content as special]
<a href="${ctx}/special/${special.id}">${special.title}</a>
[/#list]
[#--包含分页模板--]
[#include 'page.html'/]
[/@SpecialPage]