#31122 closed enhancement (invalid)
Custom orderby keys for queries
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | 4.2 |
| Component: | Query | Keywords: | |
| Focuses: | Cc: |
Description
This proposed enhancement allows for custom keys for the orderby argument in WP_Query and the accompanying mySQL clauses. This involves 2 new filters in the WP_Query method parse_orderby: allowed_orderby_keys, which allows the addition of new orderby keys other than the defaults and parse_orderby, which allows a user to create mySQL code for both new and current orderby keys.
Attachments (1)
Change History (3)
Note: See
TracTickets for help on using
tickets.
Related: #31045