以下适用于:文章,产品,招聘等模块的列表页面。
title
,keywords
,description
标签如下:标签 | 作用 | 示范 |
---|---|---|
{$catetitle} | 页面标题 | <title>{$catetitle}</title> |
{$catekey} | 页面关键字 | <meta name="keywords" content="{$catekey}"> |
{$catedesc} | 页面描述 | <meta name="description" content="{$catedesc}"> |
{$catename}
{foreach $position as $rs} <a href="{$rs['url']}" title="{$rs['name']}">{$rs['name']}</a> {/foreach}
{if count($filter)>0&&$isfilter==1} <div class="filter mb-15"> {foreach $filter as $rs} <div class="row"> <div class="col-1 filter-left">{$rs['field_title']}:</div> <div class="col-11 filter-right"> <a href="{filter_url($cateurl,$classid,deal_filter($filter_data,$rs['field_key'],0))}"{if getint(F('get.'.$rs['field_key'].''),0)==0} class="active"{/if}>全部</a> {if $rs['field_type']==14} {php $table_=$rs['field_table']}{php $join_=$rs['field_join']}{php $where_=$rs['field_where']}{php $order_=$rs['field_order']}{php $value=$rs['field_value']}{php $label=$rs['field_label']} {if $where_==''}{php $where_='1=1'}{/if} {if $order_==''}{php $order_="$value desc"}{/if} {sdcms:ra top="0" table="$table_" join="$join_" where="$where_" order="$order_"} <a href="{filter_url($cateurl,$classid,''.deal_filter($filter_data,$rs['field_key'],$ra['.$value.']))}"{if getint(F('get.'.$rs['field_key'].''),0)==$ra['.$value.']} class="active"{/if}>{$ra['.$label.']}</a> {/sdcms:ra} {else} {php $arr=explode(",",$rs['field_list'])} {foreach $arr as $j=>$key} {php $data=explode("|",$key)} <a href="{filter_url($cateurl,$classid,deal_filter($filter_data,$rs['field_key'],$data[1]))}"{if getint(F('get.'.$rs['field_key'].''),0)==$data[1]} class="active"{/if}>{$data[0]}</a> {/foreach} {/if} </div> </div> {/foreach} </div> {/if}
{cms:rs pagesize="$catepage" table="cms_content" join="$join" where="$where" order="ontop desc,ordnum desc,id desc"} 循环部分的标签格式:{$rs[字段名]} 主表和副表的任何字段均可直接调用 {/cms:rs} <div class="pagelist"><ul>{$showpage}</ul></div>