[wp-trac] [WordPress Trac] #16850: post_parent should accept an array of IDs
WordPress Trac
wp-trac at lists.automattic.com
Mon Mar 14 00:58:05 UTC 2011
#16850: post_parent should accept an array of IDs
-------------------------+-----------------------------
Reporter: scribu | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Future Release
Component: Query | Version:
Severity: normal | Resolution:
Keywords: |
-------------------------+-----------------------------
Description changed by scribu:
Old description:
> Currently, it's not possible to get a list of posts that have one of
> several parents, since the 'post_parent' query var only accepts an
> integer.
>
> And, since a post can only have a single parent, there's only one
> possible interpretation for this:
>
> {{{get_posts( array( 'post_parent' => array( 1, 2, 3 ) ) );}}}
New description:
Currently, it's not possible to get a list of posts that have one of
several parents, since the 'post_parent' query var only accepts an
integer.
And, since a post can only have a single parent, there's only one possible
interpretation for this:
{{{
get_posts( array( 'post_parent' => array( 1, 2, 3 ) ) );
}}}
Example use-case: http://wordpress.stackexchange.com/questions/11945/how-
to-get-the-parents-taxonomy/11948#11948
--
--
Ticket URL: <http://core.trac.wordpress.org/ticket/16850#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list