一般来说,无论我们在使用Typecho或者WP的时候,标签排序都是按照系统自带的随机排序格式,有些主题可能会有一些自带的排序规则。这里老蒋整理到2个网上提供的排序方法,如果有需要在设定主题的时候指定特定的标签排序的可以参考。
1、时间排序
<?php $this->widget('Widget_Metas_Tag_Cloud') ->to($taglist); ?><?php while($taglist->next()): ?>
<?php endwhile; ?>
2、文章数量排序
<?php $this->widget('Widget_Metas_Tag_Cloud', array('sort' => 'count', 'ignoreZeroCount' => true, 'desc' => true, 'limit' => 20))->to($tags); ?>
<?php while($tags->next()): ?>
自定义设置Typecho标签排序的两种方法
一般来说,无论我们在使用Typecho或者WP的时候,标签排序都是按照系统自带的随机排序格式,有些主题可能会有一些自带的排序规则。这里老蒋整理到2个网上提供的排序方法,如果有需要在设定主题的时候指定特定的标签排序的可以参考。
1、时间排序
<?php $this->widget('Widget_Metas_Tag_Cloud') ->to($taglist); ?><?php while($taglist->next()): ?>
<?php endwhile; ?>
2、文章数量排序
<?php $this->widget('Widget_Metas_Tag_Cloud', array('sort' => 'count', 'ignoreZeroCount' => true, 'desc' => true, 'limit' => 20))->to($tags); ?>
<?php while($tags->next()): ?>
猜您想看
-
情难枕-高胜美
[mp3]ht...
2019年12月22日 -
来不及认真的年轻过,就认真地老去。
...
2022年01月21日 -
早放心语:扎实一些,不要着急,你想要的,岁月都市给你
我们总是把...
2022年01月22日 -
亲情文章:怙恃之爱
天下上的爱都是...
2022年01月22日 -
您预约的游戏已经开始公测
12138年,...
2022年02月05日 -
2022.5.2
51加班,52...
2022年05月02日