How can I forbid user to delete the comments?

Hello community,

I have elgg 1.8 and my configuration is, that all user in a group can delete all other comments.

How can I set elgg, that only the own comments can deleted or no one (until the admin) can delete a comment.

Or exist a plugin for that?

Thank you very much!

     Michael

 

  • Discussions (discussion replies) or comments?

    There's a difference between comments (e.g. on blogs or other type of content) and group discussions / discussion replies. In case of comments the user who owns the entity that is commented on seems to be able to delete all comments made on it (but only the user who owns the entity). Within group discussions a user can only delete own replies.

    For group discussions the community_groups plugin (https://github.com/Elgg/community_groups) used here on the community site contains the functionality to allow for editing / deleting of group discussion replies for only 30 minutes after saving. Within this plugin this feature is limited to group discussions only but I think it might be possible to remove this limitation and then have the same functionality for normal comments made on all other type of content, too.

    You wouldn't have to use the whole community_groups plugin to add the functionality for limiting editing/deletion of replies/comments either. The necessary code is within start.php. The code consists of the registering of the plugin hook handlers (with callback function "community_groups_limit_editing") in the init function and the functions "community_groups_limit_editing()", "community_groups_can_edit()" and "community_groups_can_delete()".

  • Hello

    I have a group, and in the group there is a page.

    By the page are many comments.

    And this comments are all deleteable from the user from the group, not only from the owner of the page.

    I need, that all comments in a group (or in the whole elgg site) only deleteable from the admin of the elgg site.

    Is this possible?

    Thank's  Michael

  • Are you referring to pages created with the bundled Pages plugin? It seems that users could delete comments of others if they had write access to these pages on Elgg 1.8. On Elgg 1.9 onwards this has been fixed. So, either upgrade your site to a more recent version of Elgg or it might help to set write access of the pages to private (though this contradicts the purpose of the pages somehow).