Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

My site uses the postname Permalink.

I have a page which displays a WP_Query loop of posts of a custom post type for a given logged in User. I display both 'Pending' and 'Publish' status posts with a link to the post to view via the Single template.

OK. When the User clicks on a Publish post the page displays fine. When they click on a Pending post, they get a 404... because the link generated by post_name() doesn't generate a link with a permalink. Even if the user hand types the post ID into the browser address bar (ie. mysite.com/?p=1234) it won't work. Apparently a 'Pending' post can only be viewed by someone with a higher Role?

If so, how do I change the capabilities of a Pending post so that a logged User role can view it?

share|improve this question

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.