• Hi,

    When un-checking the Moderate Comments for a certain user, edit-comments.php is still visible in the admin bar and back-end sidebar.

    I thought hiding this with my own code would work but then realized they could manually add edit-comments.php to the URL and they won’t be restricted.

    Also, the tools.php, there is no real reason for this still being visible, how would I hide this and restrict users from these pages.

    https://www.ads-software.com/plugins/user-role-editor/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Vladimir Garagulya

    (@shinephp)

    Hi,

    Key capability for the comments moderation is the right to edit that post. More information on the subject is here:
    https://www.shinephp.com/limit-comments-moderation/
    https://shinephp.com/limit-comments-moderation-part-2/

    I think post below and followed discussion could help you to resolve the problem (pay attention on the code allowed to block use of direct URL call):
    https://shinephp.com/how-to-block-wordpress-admin-menu-item/

    Here is the reference on WordPress admin menu permissions and structure:
    https://shinephp.com/wordpress-admin-menu-permissions/

    Look on the “Admin menu editor” plugin. May be you prefer to use it, than hide menu items manually.

    Regards,
    Vladimir.

    Thread Starter iammathews

    (@iammathews)

    Hi,

    Thanks so much for your detailed input. That comment links are an extreme help knowing I can restrict the comments of a user, or the comments the user would see.

    I am more at a point where I want to restrict comments access for all users besides admin, so using my code to remove/hide an admin menu, I would like to accompany it with “You do not have sufficient permissions to access this page.” when going to that link – your response just sends the user back.

    How would I achieve this? The “admin menu editor” plugin is quite nify and will work well. Only thing is, I don’t understand why your plugin can’t do this – since I bought your plugin and it’s along the same lines, I am not going to purchase another plugin.

    Regards,
    Yusri

    Plugin Author Vladimir Garagulya

    (@shinephp)

    Hi Yusri,

    I may help you with code to achieve directly that what you wish. Just wait until I return from the holiday trip – September, 18th. We will discuss your task in details later, when I will have regular access to the Internet and my developer’s desktop.

    P.S. I do not plan to include “Admin Menu Editor” functionality in User Role Editor plugin, while the author of AME does not come on the User Role Editor territory. It is a question of developers ethics from my point of view. We just recommend users to look on the related product of each other, if it could help.

    Regards,
    Vladimir.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Restrict Comments & Tools’ is closed to new replies.