Title: Random order WC3
Last modified: May 18, 2017

---

# Random order WC3

 *  Resolved [en10](https://wordpress.org/support/users/en10/)
 * (@en10)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/random-order-wc3/)
 * Hello,
 * I use WooCommerce 2 and updated to the last update of WooCommerce 3.
 * In my home, I use a random order with a function in functions.php
 *     ```
        add_filter('woocommerce_get_catalog_ordering_args', 'set_sort_order');
         function set_sort_order($args) {
           $args['orderby'] = 'rand';
           return ($args);    
         }
       ```
   
 * With WC2.6 it worked but I think after updated WC3, this code doesn’t work.
 * Is there some change with WC3?
 * Thank you and best regards
 * EDIT: or maybe the new products are display before the other even if there is
   random order?… Is it possible? (think)
    -  This topic was modified 9 years, 5 months ago by [en10](https://wordpress.org/support/users/en10/).

Viewing 1 replies (of 1 total)

 *  Thread Starter [en10](https://wordpress.org/support/users/en10/)
 * (@en10)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/random-order-wc3/#post-9173560)
 * An external plugin forced his order.
    I fixed it and now it’s ok.

Viewing 1 replies (of 1 total)

 The topic ‘Random order WC3’ is closed to new replies.

 * ![](https://ps.w.org/woocommerce/assets/icon.svg?rev=3640790)
 * [WooCommerce](https://wordpress.org/plugins/woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce/reviews/)

## Tags

 * [order](https://wordpress.org/support/topic-tag/order/)

 * 1 reply
 * 1 participant
 * Last reply from: [en10](https://wordpress.org/support/users/en10/)
 * Last activity: [9 years, 4 months ago](https://wordpress.org/support/topic/random-order-wc3/#post-9173560)
 * Status: resolved