• For those who have experimented with WordPress CMS functionality (especially those using Role Manager, et al), has anyone found a way to allow a general user to publish AND edit a published post, but NOT edit or delete other peoples’ comments from that post?

    I’ve tried this every which way, but it appears that the two go hand-in-hand. If I want to give users the ability to edit published posts, they automatically get the ability to edit/delete comments within their post – even if that comment is from a role “higher” than them, or from blog admin!

    Anyone found a way around this? It’s important for the current vision of my blog that users be able to edit and update their posts by not edit or delete others’ comments from that post at will. (FYI, no coding experience, but willing to dig through the .php files and try to figure it out.)

    Thanks in advance.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter asechrest

    (@asechrest)

    Update: I’ve experimented with a bunch of combinations of plugins and restrictions within those plugins. I just can’t seem to get it done.

    At this point I’d settle for something that simply masks a user’s ability to edit/delete comments in their post while still retaining the ability to publish and edit their original post.

    If no one knows of a plugin that could do this, are there some code adjustments that could be made?

    Thanks.

    if you’re still interested, I made something similar today. but i’ve done it by modifying theme files, as my theme was overriding WordPress original comments.
    you need to find in your theme the place where your link gets placed in the comment and wrap it between 2 lines of code:
    this one goes before:
    <?php if (current_user_can('moderate_comments')) : ?>

    and this one goes after:
    <?php endif;?>

    however, this is only a hack. it prevents the display of the link to comment editing page.
    if a user is smart enough to duplicate the exact address of that page (with action name and comment number) he might be able to modify the comment. not very likely, but possible.

    i am looking for this exact same plugin/hack.

    The closest I got was: https://www.laboratoriocaffeina.it/development/2007/07/20/restrict-authors-access-to-edit-comments-the-plugin.html

    However, it still gave the user the link – but it just went to a restricted page. Plus, this overrides the actual “author” role, which I want to keep. I just want to either add a new role with this tweek or allow the admin of the blog to restrict that user’s permission.

    I’m using wpmu and basically the students have blogs and they are an “author” but when a teacher comments on their post the student can edit her comment – which is exactly what I don’t want.

    I think the problem is separating “can edit published posts” and “editing comments” because when I turn the “can edit published posts” OFF (with capability manager plugin) it does not allow editing of comments. I do want them to edit their published posts… yet not edit comments…

    There has to be a plugin, I’m continuing to search.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Prevent Non-Admin Role From Editing/Deleting Comments’ is closed to new replies.