[wp-trac] [WordPress Trac] #24684: posts_clauses Query filter should have array as argument
WordPress Trac
noreply at wordpress.org
Mon Aug 12 16:00:29 UTC 2013
#24684: posts_clauses Query filter should have array as argument
-------------------------+------------------------------
Reporter: F J Kaiser | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Query | Version: 3.5.2
Severity: normal | Resolution:
Keywords: needs-patch |
-------------------------+------------------------------
Changes (by F J Kaiser):
* keywords: needs-patch close => needs-patch
Comment:
Replying to [comment:3 wonderboymusic]:
> This would just end up being a 3rd argument to the `post_clauses` filter
(back compat) and would be a major rewrite of `get_posts()` - unless a
patch materializes that nails it, I don't see this picking up any steam
You misread something: There would be ''no'' 3rd argument and ''no'' major
rewrite. Actually the patch would ''just'' replace all the string
concatenating with array pushing. All the filters and the vars would then
just get converted from Array > String using a simple
{{{join()}}}/{{{implode()}}} before they'd get called.
The new filter would run ''after'' the current filters so nothing would
break and everything would be backwards compatible. Plugins could slowly
move towards using the newer (easier and faster) filter.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/24684#comment:4>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list