Title: Admin Interface Reverse Chronological Order
Last modified: August 19, 2016

---

# Admin Interface Reverse Chronological Order

 *  [Ellis Benus](https://wordpress.org/support/users/glaxton/)
 * (@glaxton)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/admin-interface-reverse-chronological-order-1/)
 * I would like to write a plugin which reverses the chronological order posts are
   displayed in the Edit Posts page of the WordPress administration panel.
 * The following post shows how to change the hard coding of the wp-admin/includes/
   post.php file, but this needs to be accomplished without changing the core wordpress
   files.
 * The function that needs to be changed is wp_edit_posts_query() as the above article
   points out.
 * The block of code as it appears normally is:
 *     ```
       if ( isset($q['post_status']) && 'pending' === $q['post_status'] ) {
       		$order = 'ASC';
       		$orderby = 'modified';
       	} elseif ( isset($q['post_status']) && 'draft' === $q['post_status'] ) {
       		$order = 'DESC';
       		$orderby = 'modified';
       	} else {
       		$order = 'DESC';
       		$orderby = 'date';
       	}
       ```
   
 * To accomplish this task, it needs to be changed to:
 *     ```
       if ( isset($q['post_status']) && 'pending' === $q['post_status'] ) {
       		$order = 'ASC';
       		$orderby = 'modified';
       	} elseif ( isset($q['post_status']) && 'draft' === $q['post_status'] ) {
       		$order = 'ASC';
       		$orderby = 'modified';
       	} else {
       		$order = 'ASC';
       		$orderby = 'date';
       	}
       ```
   
 * Basically, just changing DESC to ASC.
 * Any help would be appreciated.

Viewing 1 replies (of 1 total)

 *  [MichaelH](https://wordpress.org/support/users/michaelh/)
 * (@michaelh)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/admin-interface-reverse-chronological-order-1/#post-1339658)
 * Something to consider:
    [http://wordpress.org/support/topic/336715](http://wordpress.org/support/topic/336715)

Viewing 1 replies (of 1 total)

The topic ‘Admin Interface Reverse Chronological Order’ is closed to new replies.

## Tags

 * [admin](https://wordpress.org/support/topic-tag/admin/)
 * [chronological](https://wordpress.org/support/topic-tag/chronological/)
 * [dashboard](https://wordpress.org/support/topic-tag/dashboard/)
 * [order](https://wordpress.org/support/topic-tag/order/)
 * [post](https://wordpress.org/support/topic-tag/post/)
 * [post order](https://wordpress.org/support/topic-tag/post-order/)
 * [reverse](https://wordpress.org/support/topic-tag/reverse/)

 * 1 reply
 * 2 participants
 * Last reply from: [MichaelH](https://wordpress.org/support/users/michaelh/)
 * Last activity: [16 years, 4 months ago](https://wordpress.org/support/topic/admin-interface-reverse-chronological-order-1/#post-1339658)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
