[wp-trac] [WordPress Trac] #19041: function to list all (true) conditionals (in an array)

WordPress Trac wp-trac at lists.automattic.com
Mon Oct 24 20:53:39 UTC 2011


#19041: function to list all (true) conditionals (in an array)
-------------------------+-----------------------------------
 Reporter:  F J Kaiser   |      Owner:
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  Query        |    Version:  3.3
 Severity:  normal       |   Keywords:  has-patch 2nd-opinion
-------------------------+-----------------------------------
 Often we need to check against a lot of conditionals. It would be handy to
 have one "mother" function to retrieve those query conditionals that are
 set true with a single call.

 The attached patch introduces a new function {{{get_conditionals();}}}
 that returns a numerical indexed array containing all object parts of
 {{{$GLOBALS['wp_query'];}}} that start with {{{is_}}} and are set to true.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/19041>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list