[wp-trac] [WordPress Trac] #18832: wp_get_archives should allow for Ascending and Descending ordering

WordPress Trac wp-trac at lists.automattic.com
Fri Sep 30 21:37:25 UTC 2011


#18832: wp_get_archives should allow for Ascending and Descending ordering
-------------------------+-----------------------------
 Reporter:  tar.gz       |      Owner:
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  General      |    Version:
 Severity:  normal       |   Keywords:
-------------------------+-----------------------------
 The wp_get_archives function offers various options for listing content by
 year, month, week, day, postname.

 However, it offers only one sorting direction: from the newest to the
 oldest. This makes certainly sense in the classical WP use case: a blog.
 But since WP is now a full-featured CMS, it seems logical that the choice
 of the sorting order should be left to the user.

 It should be possible to define this direction by using order=ASC /
 order=DESC.

 If the option gets introduced, but the default left at the current state
 (order=DESC), the change would not affect existing sites while improving
 the overall functionality.

 This feature has been requested by several users over the years:

 http://wordpress.org/support/topic/sort-posts-in-ascending-order-through-
 wp_get_archives

 http://wordpress.org/support/topic/chronological-sidebar-
 archives?replies=3

 http://wordpress.org/support/topic/monthly-archives-
 ascendingdescending?replies=15

 http://wordpress.org/support/topic/archives-index-ascending-
 order?replies=4

 http://wordpress.org/support/topic/archives-ascending?replies=6

 Some people try to solve the problem by editing the core files:

 http://www.bestwpthemez.com/wordpress/how-to-set-archives-list-in-
 ascending-order-1633/

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/18832>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list