So, I'm trying to create a number of custom roles within my theme to meet with the custom requirements of the site.

The first, and most simple, being 'external viewer' who I want to simply be able to view posts (both built in and custom post-types) that someone else on the content team has created and scheduled for some point in the future.

Initially I tried this

$viewer_capabilities = array(
    'read_private_pages' => true,
    'read_private_posts' => true,
    'read' => true

add_role('external_viewer', 'External Viewer', $viewer_capabilities );

But when logging into /wp-admin I just got the 'no permission' message and I couldn't do anything. If I went to one of the scheduled posts, I just got 'not found'.

So then I tried

$role_object = get_role( 'external_viewer' );
$role_object->add_cap( 'read_private_pages' );
$role_object->add_cap( 'read_private_posts' );
$role_object->add_cap( 'read' );

Which got me a little further. I can login and see the admin dashboard, but if I visit a scheduled post, then I still get 'page not found'.

Can anyone see what I'm missing?

1 Answer 1


I found Future posts are not exactly a different capability.

In WordPress Roles and Capabilities I found edit_others_posts is available by default for Super Admin, Administrator and Editor. I think it will be a right way you can proceed. (Not tested though)

And additionally try with edit_published_posts, publish_posts etc.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.