[wp-trac] [WordPress Trac] #28568: Can't get private posts/pages via WP_Query when not logged in as administrator

WordPress Trac noreply at wordpress.org
Tue Jun 17 20:15:35 UTC 2014


#28568: Can't get private posts/pages via WP_Query when not logged in as
administrator
--------------------------+------------------------------
 Reporter:  mklusak       |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Query         |     Version:  3.9
 Severity:  normal        |  Resolution:
 Keywords:  close         |     Focuses:
--------------------------+------------------------------
Changes (by mklusak):

 * keywords:  close reporter-feedback => close


Comment:

 Well, I have my reasons. For example I don't want that page URL to be
 indexable, but I want its content displayed somewhere...

 This is "magic" behaviour for me. I want exact post/page... using the most
 proper WP function... and I don't get it. Even when I know it is private
 and I am declaring it in arguments array.

 If this is a feature, then it should be mentioned in Codex: "You can't use
 post_status => private on front-end, it works only for logged in users".

--
Ticket URL: <https://core.trac.wordpress.org/ticket/28568#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list