Title: Default order in User&#039;s list
Last modified: August 20, 2016

---

# Default order in User's list

 *  Resolved [MacItaly](https://wordpress.org/support/users/macitaly/)
 * (@macitaly)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/default-order-in-users-list/)
 * Hi José,
    first of all thanks for this useful plugin, by far the only one I tried
   that is effective against sploggers. Only a little thing that should be comfy:
   as sometimes some splogger (reasonable few, I have around 100/200 attempt per
   day in one site and only a handful per week across the shield) pass, to check
   them I go on user list, click on last registration (default is username ordered)
   column, click again because order is Ascending and finally have the last subscribed,
   where I find the sploggers and can delete.
 * Should be quicker, if I could enter in User list and find it ordered by last 
   subscribed.
    So, my question is: how I can achieve this? where I have to modify
   to change default order? Or, better, could you consider to make this optional,
   in a next release? Thanks in advance
 * Mac
 * [http://wordpress.org/extend/plugins/wangguard/](http://wordpress.org/extend/plugins/wangguard/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Jose Conti](https://wordpress.org/support/users/jconti/)
 * (@jconti)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/default-order-in-users-list/#post-3585702)
 * Thanks a lot MacItaly
 * The users screen needs a lot of improving, I know it 🙁
 * Now, we are centered in improving to detect Sploggers, especially the Chinese.
 * I don’t remember know, I will look into the code, and I will explain you how 
   to change the order.
 * Kind regards
 *  Plugin Author [Jose Conti](https://wordpress.org/support/users/jconti/)
 * (@jconti)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/default-order-in-users-list/#post-3585774)
 * Hi MacItaly,
 * Sorry for the delay.
 * Open the file wangguard-class-wp-users.php
 * Look for the line 371.
 * You will find there this:
 *     ```
       function __construct( $query = null ) {
       		if ( !empty( $query ) ) {
       			$this->query_vars = wp_parse_args( $query, array(
       				'orderby' => 'login',
       				'order' => 'ASC',
       				'search' => '',
       				'offset' => '',
       				'number' => '',
       				'type' => '',
       				'count_total' => true
       			) );
   
       			$this->prepare_query();
       			$this->query();
       		}
       	}
       ```
   
 * You only needs to modify this lines:
 *     ```
       'orderby' => 'login',
       'order' => 'ASC',
       ```
   
 * by
 *     ```
       'orderby' => 'user_registered',
       'order' => 'DESC',
       ```
   
 * Thats all.
 * In the next minor version (in a few days) I will add this by Default
 * Kind regards
 *  Thread Starter [MacItaly](https://wordpress.org/support/users/macitaly/)
 * (@macitaly)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/default-order-in-users-list/#post-3585776)
 * Hi José,
    thanks a lot, it works perfectly (of course :), this is a little modify
   but useful. Wanguard is a great defense against sploggers, the best I tried so
   far (and tried all of them). Kind Regards,
 * Mac
 *  Plugin Author [Jose Conti](https://wordpress.org/support/users/jconti/)
 * (@jconti)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/default-order-in-users-list/#post-3585792)
 * Happy to be helpful 😉

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Default order in User's list’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wangguard_c6c6c6.svg)
 * [WangGuard](https://wordpress.org/plugins/wangguard/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wangguard/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wangguard/)
 * [Active Topics](https://wordpress.org/support/plugin/wangguard/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wangguard/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wangguard/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [Jose Conti](https://wordpress.org/support/users/jconti/)
 * Last activity: [13 years, 1 month ago](https://wordpress.org/support/topic/default-order-in-users-list/#post-3585792)
 * Status: resolved