Title: random orderby
Last modified: March 18, 2021

---

# random orderby

 *  Resolved [checksumdk](https://wordpress.org/support/users/checksumdk/)
 * (@checksumdk)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/random-orderby/)
 * Hi
    I would like to set the sponsors block or shortcode to orderby=”Random” like
   I can do in the widget. I cannot make work currently with this code:
 * [sponsors orderby=”random” style=”grid”]

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

 *  Plugin Author [Igor Benic](https://wordpress.org/support/users/ibenic/)
 * (@ibenic)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/random-orderby/#post-14201005)
 * Hi [@checksumdk](https://wordpress.org/support/users/checksumdk/), you should
   be able to order them randomly if you use ‘rand’ instead of random.
 * Since it uses the get_posts function, all orderby options can be seen here: [https://developer.wordpress.org/reference/classes/wp_query/#order-orderby-parameters](https://developer.wordpress.org/reference/classes/wp_query/#order-orderby-parameters)
 *  Thread Starter [checksumdk](https://wordpress.org/support/users/checksumdk/)
 * (@checksumdk)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/random-orderby/#post-14201039)
 * Super cool. Thanks. The random string was a guess inspired by the text in the
   widget settings.
    It works great with rand 🙂
 * Thanks

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

The topic ‘random orderby’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-sponsors_e7e7e7.svg)
 * [Sponsors](https://wordpress.org/plugins/wp-sponsors/)
 * [Support Threads](https://wordpress.org/support/plugin/wp-sponsors/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-sponsors/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-sponsors/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-sponsors/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [checksumdk](https://wordpress.org/support/users/checksumdk/)
 * Last activity: [5 years, 2 months ago](https://wordpress.org/support/topic/random-orderby/#post-14201039)
 * Status: resolved