[wp-trac] [WordPress Trac] #17065: Independent ASC/DESC in multiple ORDER BY statement.
WordPress Trac
noreply at wordpress.org
Tue Jul 8 17:15:55 UTC 2014
#17065: Independent ASC/DESC in multiple ORDER BY statement.
-------------------------+-----------------------
Reporter: ericmann | Owner: ericmann
Type: enhancement | Status: new
Priority: normal | Milestone: 4.0
Component: Query | Version: 3.1
Severity: normal | Resolution:
Keywords: has-patch | Focuses:
-------------------------+-----------------------
Comment (by wonderboymusic):
In [changeset:"29027"]:
{{{
#!CommitTicketReference repository="" revision="29027"
Allow an `array()` to be passed as the value for `orderby` to `WP_Query`.
Allows for an independent `order` value for each key.
Example: `'orderby' => array( 'title' => 'DESC', 'menu_order' => 'ASC' )`.
Adds docs and unit tests.
Props wonderboymusic, johnbillion, DrewAPicture, dd32, andy.
See #17065.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/17065#comment:67>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list