Home >CMS Tutorial >DEDECMS >How to sort the Dreamweaver TAG tag list by latest release time
How to sort the Dreamweaver TAG tag list by the latest release time
Nowadays, search engines attach great importance to TAG. Solve the problem that the TAG list of DedeCms is sorted by the latest release time, which can effectively provide the latest TAG to users and search engines. (Recommended tutorial: dedecms tutorial)
Solution:
Find the /include/arc.taglist.class.php file (about 313 lines), find the code:
$this->dsql->SetQuery("SELECT aid FROM `dede_taglist` WHERE tid = '{$this->TagInfos['id']}' AND arcrank>-1 LIMIT $limitstart,$getrow");
Modify to:
$this->dsql->SetQuery("SELECT aid FROM `dede_taglist` WHERE tid = '{$this->TagInfos['id']}' AND arcrank>-1 order by aid desc LIMIT $limitstart,$getrow");
Description: Earlier version of dede_taglist is dede_taglist. After modification, the order of the TAG list will be based on the latest publication time of the article.
The above is the detailed content of How to sort the Dreamweaver TAG tag list by latest release time. For more information, please follow other related articles on the PHP Chinese website!