[wp-trac] [WordPress Trac] #11197: WP_Query post__not_in parameter ignored for sticky posts

WordPress Trac wp-trac at lists.automattic.com
Fri Nov 20 13:08:27 UTC 2009


#11197: WP_Query post__not_in parameter ignored for sticky posts
--------------------------+-------------------------------------------------
 Reporter:  tidywebdev    |       Owner:                 
     Type:  defect (bug)  |      Status:  new            
 Priority:  low           |   Milestone:  Unassigned     
Component:  General       |     Version:  2.8.6          
 Severity:  minor         |    Keywords:  sticky WP_Query
--------------------------+-------------------------------------------------
 If you specify an array of post IDs for the post__not_in parameter when
 doing a custom query using a WP_Query object, the posts will still be
 returned if they are sticky.

 The only way to avoid this is to also include the caller_get_posts=1
 parameter, which stops the sticky posts appearing at the top of the post
 list, thus losing some of the sticky functionality.

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


More information about the wp-trac mailing list