[wp-trac] [WordPress Trac] #20267: Query_Posts not matching Custom Post Type, Taxonomy and Post-id values

WordPress Trac wp-trac at lists.automattic.com
Wed Mar 21 00:42:41 UTC 2012


#20267: Query_Posts not matching Custom Post Type, Taxonomy and Post-id values
--------------------------+-----------------------------
 Reporter:  arena         |      Owner:  arena
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Query         |    Version:  3.4
 Severity:  normal        |   Keywords:  dev-feedback
--------------------------+-----------------------------
 I have created 1 custom Post Type (cpt)
 + 1 taxonomy (taxo) related to custom post type cpt.

 i created 2 taxonomy terms (slugs : 'first_cat' & '2nd_cat')

 I created a 'cpt' (id : 22) and "categorized" it to first_cat

 When i do a query_posts with following arguments :


 {{{
 array (
 "taxo" => "2nd_cat",
 "post_type" => "cpt",
 "p" => 22
 )
 }}}

 the query_posts retrieves post 22 but should not due to taxo value !?

 ps : i followed sample given in http://codex.wordpress.org/Taxonomies

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


More information about the wp-trac mailing list