[wp-trac] Re: [WordPress Trac] #6939: wp_list_pages() should also lists private pages if the user has capability 'read_private_pages'

WordPress Trac wp-trac at lists.automattic.com
Sun Sep 14 22:28:08 GMT 2008


#6939: wp_list_pages() should also lists private pages if the user has capability
'read_private_pages'
----------------------------------------------------------+-----------------
 Reporter:  imwebgefunden                                 |        Owner:  anonymous
     Type:  defect                                        |       Status:  new      
 Priority:  normal                                        |    Milestone:  2.9      
Component:  Template                                      |      Version:  2.5.1    
 Severity:  normal                                        |   Resolution:           
 Keywords:  wp_list_pages, read_private_pages, has-patch  |  
----------------------------------------------------------+-----------------
Changes (by rovo89):

  * keywords:  wp_list_pages, read_private_pages => wp_list_pages,
               read_private_pages, has-patch

Comment:

 I agree that this is a very useful patch and should be included in the
 next release. That is the one thing I have to change in the core after
 each update, although I use:

 {{{
 ... WHERE (post_type = 'page' AND " . get_private_posts_cap_sql('page') .
 ") ...
 }}}

 The {{{get_private_posts_cap_sql}}} function does basically the same as in
 the patch here, but is already included in Wordpress and additionally
 lists the user's own private pages, even if they have no permission to
 read private posts.

-- 
Ticket URL: <http://trac.wordpress.org/ticket/6939#comment:4>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list