[wp-trac] [WordPress Trac] #21875: get_categories orderby random

WordPress Trac wp-trac at lists.automattic.com
Wed Sep 12 11:38:02 UTC 2012


#21875: get_categories orderby random
-------------------------+----------------------
 Reporter:  Ninos Ego    |       Owner:
     Type:  enhancement  |      Status:  closed
 Priority:  normal       |   Milestone:
Component:  Taxonomy     |     Version:  3.4.2
 Severity:  trivial      |  Resolution:  wontfix
 Keywords:               |
-------------------------+----------------------
Changes (by scribu):

 * status:  new => closed
 * resolution:   => wontfix
 * milestone:  Awaiting Review =>


Comment:

 Unlike get_posts(), get_categories() doesn't have pagination, So you can
 just use shuffle():

 {{{
 $categories = get_categories();

 shuffle( $categories );
 }}}

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/21875#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list