muban大师 发表于 2021-5-17 12:01:18

dedecms织梦模板文章按权重排序的标签教程

dede:arclist 这个标签官方程序是支持按权重调用文章的,正确的标签写法是这样的
        {dede:arclist typeid='1' row='8' isweight='y'} [*,权重: {/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
页: [1]
查看完整版本: dedecms织梦模板文章按权重排序的标签教程