//排序方式
$ordersql = '';
if($orderby=="senddate" || $orderby=="id") {
$ordersql=" ORDER BY arc.id $orderWay";
}
else if($orderby=="hot" || $orderby=="click") {
$ordersql = " ORDER BY arc.click $orderWay";
}
else if($orderby=="lastpost") {
$ordersql = " ORDER BY arc.lastpost $orderWay";
}
sql = " ORDER BY arc.weight $orderWay";
else {
$ordersql=" ORDER BY arc.sortrank $orderWay";
}
3、再在第778行处找到此段代码
//如果不用默认的sortrank或id排序,使用联合查询(数据量大时非常缓慢)
if(preg_match('/hot|click|lastpost|/',$orderby))
{dede:list }//这里的顺序可以改为desec(注释:这里是按照从大到小排序)
原文链接:https://www.f2er.com/dedecms/403995.html