I am setting up a site where there will be multiple users as Author, the owner doesn’t want the authors to be able to view each others posts, since there are some meta fields with information he’d rather not have shared between the authors.
Is there a way to remove the ability to view other authors posts?
Thanks,
Chuck
To clarify a bit more, this is for the admin side, at the top underneath Posts, there are links for mine, all, and published. I only want Authors to see “mine”.
If you want to prevent a user with the “Author” role to view other users’ posts in the overview screen (they won’t be able to view the details anyway), you can add an extra filter on the author:
The little links above the post table (“Mine”, “All”, “Drafts”) are less useful now, you can also remove them:
That is exactly what the default “author” role does.
http://codex.wordpress.org/Roles_and_Capabilities
Just check for capabilities (See link from @Wyck) & the author ID inside your templates and put the stuff you don’t want others to see inside an if/else check:
I had to do something like this today and this is why I found this post. What I found that worked for me was this post titled: “How to Limit Authors to their Own Posts in WordPress Admin” by wpbeginner
Here is the code that you can paste on your functions.php:
Have a look here for a more complete solution (to also fix the post count on the filter bar): Help to condense/optimize some working code