Archived topic
Edit post/page link for Editor
5 replies · Started by Matthew on August 17, 2016
Hi,
We have demoted most of our users from Admin to Editor. They are now complaining that the top admin bar is missing so they can't use the 'edit this page' option.
I read that some schemes insert an 'edit' link into pages/posts when the user is logged in. I can't see this in your theme. Does it exist, can it be enabled/added?
i.e.
<?php edit_post_link('(Edit this post)', '<p>', '</p>'); ?>
Thanks, Matt
Hi Matt,
This might help: https://generatepress.com/forums/topic/update-problem-with-gp-premium/#post-191096
Let me know :)
Hi,
That works for Admin users but not for Editors. I've looked at the source code for edit_post_link and can't explain why that would be the case. We tried making our test user an Author as well and still no link.
We do not want our Editors to be Admins, but have failed to display the edit link or cut down admin bar for them to quickly adjust a page/post. Any suggestions?
Matt
Here's what the function says it does:
Returns edit post url as string value, provided the current user has the 'edit_post' capability
So if the editors have the "edit_post" capability, it should show up.
Have you done anything to edit capabilities maybe?
Yes, we read that and confirmed that edit_post is a default role for Editor. However the code you provided only works for Administrators. We are now stuck...
Thanks again for the great support.
Hmm, something is wrong with your installation then.
It could be a plugin altering the roles, not sure.
You could try playing with a plugin like this: https://en-ca.wordpress.org/plugins/user-role-editor/