全国400电话网上服务平台
强大号码库资源任选,方便,快捷,快速开通。
咨询热线:400-1100-266
强大号码库资源任选,方便,快捷,快速开通。
咨询热线:400-1100-266
dedecms织梦模板文章按权重排序的标签教程
POST TIME:2021-05-23 02:23
dede:arclist 这个标签官方程序是支持按权重调用文章的,正确的标签写法是这样的
{dede:arclist typeid='1' row='8' isweight='y'} <li><span>权重:[field:weight /]</span><a href="[field:arcurl /]">[field:title /]</a></li> {/dede:arclist}
列表要按权重排序的话,需要打开 includearc.listview.class.php 找到
else if($orderby=="lastpost") { $ordersql = " ORDER BY arc.lastpost $orderWay"; }
在它的下面加上
else if($orderby == 'weight') { $ordersql = " ORDER BY arc.weight $orderWay"; }
继续找到
/hot|click|lastpost
改成
/hot|click|lastpost|weight
{dede:arclist typeid='1' row='8' isweight='y'} <li><span>权重:[field:weight /]</span><a href="[field:arcurl /]">[field:title /]</a></li> {/dede:arclist}
列表要按权重排序的话,需要打开 includearc.listview.class.php 找到
else if($orderby=="lastpost") { $ordersql = " ORDER BY arc.lastpost $orderWay"; }
在它的下面加上
else if($orderby == 'weight') { $ordersql = " ORDER BY arc.weight $orderWay"; }
继续找到
/hot|click|lastpost
改成
/hot|click|lastpost|weight
Copyright © 2003-2016
时间:9:00-21:00 (节假日不休)
版权所有:巨人网络(扬州)科技有限公司
总部地址:江苏省信息产业基地11号楼四层
《增值电信业务经营许可证》 苏B2-20120278

时间:9:00-21:00 (节假日不休)
版权所有:巨人网络(扬州)科技有限公司
总部地址:江苏省信息产业基地11号楼四层
《增值电信业务经营许可证》 苏B2-20120278

