Hello. I am wondering if it is possible to re-sort the post order of a category archive page using in-page links (i.e. "Re-sort posts by Title" link, "Re-sort posts by Date" link, etc.).
Thanks!
Hello. I am wondering if it is possible to re-sort the post order of a category archive page using in-page links (i.e. "Re-sort posts by Title" link, "Re-sort posts by Date" link, etc.).
Thanks!
In the proper archive template, add this before the loop:
query_posts($query_string . '&orderby=title&order=ASC')
Related:
Stepping Into Template Tags
Stepping Into Templates
Template Hierarchy
My question is: is there a way for a visitor to manually re-order posts using a set of links on the sidebar? Like this:
Order posts by Name
Order posts by Date
And when a visitor clicks on either one, it re-sorts the page according to that order?
Thanks.
Could provide these as links (Note 1st example shows WordPress installed in a sub-folder of web-root:
http://yourdomain.com/wordpress/?orderby=title&order=ASC
http://yourdomain.com/?orderby=date&order=DESCThis topic has been closed to new replies.