@H_404_0@露兜博客首页的访客可自行选择文章排序方式的效果是怎么做的,今天就来给大家分享这个文章排序效果的实现过程。
文章排序
- <a <?php if ( isset($_GET['order']) && ($_GET['order']=='rand') ) echo 'class="current"'; ?> href="/?order=rand" rel="nofollow">随机阅读
- <a <?php if ( isset($_GET['order']) && ($_GET['order']=='commented') ) echo 'class="current"'; ?> href="/?order=commented" rel="nofollow">评论最多
- <a <?php if ( isset($_GET['order']) && ($_GET['order']=='alpha') ) echo 'class="current"'; ?> href="/?order=alpha" rel="nofollow">标题排序