AJAX Report Comments

v 2.0.4

If you are installing this plugin over version 1, you will need to deactivate and reactivate it prior to using it.

AJAX Report Comments is a powerful add-on for any WordPress blog, particularly larger blogs with a higher volume of user comments. It provides blog visitors the ability to report an inappropriate comment to the blog’s moderator with a single click using AJAX and email. You can even enable a ‘comment’ box so your users can say why they are flagging the comment.

Through the WordPress Admin you can modify many aspects of the plugin including the text of the “Report Comment” link, setting a threshold for the number of reports before hiding the comment on the front end, the “Thank you” message for enabled email notifications, the email address to send the inappropriate comment to and the layout and content of the generated email itself. You can even modify the HTML surrounding the “Report Comment” link to suit your needs.

After a comment is reported, any site moderator / administrator can log into the WordPress admin and moderated the comments. Once a comment is approved, users can no longer report it. A comment can additionally be edited or deleted from the plugin’s moderation panel. You can even view a report per comment which includes the original posting author as well as all users who have flagged the comment. If you’ve enabled the email notify feature, the email address you specify will receive a message including the text of the reported comment and a link to view the comment on the site.

Installation:

  1. Download and unzip the above file
  2. Upload the entire report-comments directory to your plugins directory
  3. Activate the plugin from the WordPress admin panel
  4. Configure the options under the admin panel: Options – AJAX Report Comments

Change Log:

v2.0.4

  • Disabled caching level which causes most of the plugin to fail.

v2.0.3

  • Fixing syntax error in report-comments.php
  • Fixed a layout issue where the footer appeared on top of the list of comments in some cases.
  • Resolved issue where multiple reports for the same comment from the same computer were not blocked.
  • Fixed an issue where the wrong IP address was displayed on the moderation screen under Commenter’s IP

v2.0.2

  • Fixing syntax error in report-comments.php

v2.0.1

  • Fixing conflict with ‘Role Scoper’ plugin where pluggable.php was not required on plugin forward facing pages.

v2.0

  • Reported comments are available in a moderation system inside WP for site admins / moderators.
  • Added dashboard integration for moderation panel.
  • Moved plugin to own widget navigation.
  • Once a flagged comment is approved by a site administrator / moderator, it cannot be flagged again by front end users.
  • Can view a report on a single comment to see how many times it has been reported as well as details of original comment poster and users who flagged the comment.
  • Admins can set a threshold value where if a comment is reported more times then the number specified, it automatically hides from the site’s front end.
  • Enable / Disable reported comment reason box where users can give a reason for reporting a comment.
  • Enable / Disable email moderator function.

74 Responses to “AJAX Report Comments”

  1. blogger says:

    This plugin doesn’t work well. For example, well you click on report comment, one does not even know when the comment has been submitted. Please help!

    Report this comment

  2. gentry says:

    hey – super cool and sorry to add to your workload but i’m struggling a bit. seems the plugin works in that the link appears, i can click it to open a text area, i can fill in that text area and the report gets sent over email, but after the user clicks submits the report nothing happens for them — the text area doesn’t close down, there’s no confirmation message — as far as they know it just didn’t work. weird, eh?

    not sure what i’m doing wrong… if you check the website you’ll see the button is above the comment area. i had to hack that to get it to work but i don’t think it’s related, as i seem to have the problem in both un-hacked (out-of-box) form, as well as hacked…

    thanks in advance.

    Report this comment

  3. aj says:

    Hey buddy,

    Fantastic plugin… works Perfect!

    Just wondering if you could add a “Cancel” button
    right next to the “Report Comment” button please?

    That way it would give the “whinging” user an
    option whether to report it or not…

    resulting in less moderation :)

    would happily send you a $10 beer via paypal
    for this little mod.

    coz I totally suck at php/wp lol.

    - aj

    Report this comment

  4. Patrick says:

    Looks like a great plugin.

    I’m having trouble with this on WP 3.0.1.

    I get a 404 error on /wp-content/plugins/reports-comments/report.php

    Report this comment

    • Patrick says:

      Sorry. I should clarify.

      First – I see that I mistyped the your plugin directory. I meant to type /wp-content/plugins/report-comments/report.php

      Second – I double-checked and the file does exist in that directory.

      Report this comment

  5. WM Weblog says:

    Hey

    Great plugin! but unfortunately I met some problems.

    After reporting a comment it looks like nothing happens. But the email is sent but no that you for reporting message pops up or anything.

    And the “hide reported comments” function really hides the comment altogether and comment count still shows for instance “2 comments on this post” while a visitor cant see any comments at all. Could this be modified to work as the comment system on youtube where users can click a “show” button to see the comment even tho they have been warned that the comment has been reported?

    Once again thanks for a great plugin

    Alex.

    Report this comment

  6. Hussain says:

    I tried to enable this plugin, it works, i get the moderation, however when a user clicks the submit button, the error or success mesage is not displayed, basically nothing happens on the front end.

    Any ideas?

    Report this comment

  7. Ariel says:

    My biggest request: a way for users to CANCEL reporting the comment. My users often erroneously click “report” (confusing it with “reply”) and once the text box to explain why they’re reporting pops up, there’s no way to get rid of it other than submitting.

    Report this comment

  8. Stefan says:

    Hello!

    Nice and useful plugin, but just to let you know, it doesn’t work with the latest RC2 of WordPress. I tested in on two different blogs.

    Please, can you tell me all the tables created with this plugin, so I can drop them and reinstall it. Maybe there’s the problem, because I’ve overwrite the previous version without deactivating it first.

    Actually, the plugin is working, but when a user press Report, the text is still there and there is no indication or a message that a comment has been reported. On the other hand, the comment is marked as reported.

    P.S. And something small and not so important: with split screen (4 field in my case) in WP’s Dashboard, the text is hidden under the other widgets.

    Report this comment

  9. paul bearne says:

    Got a strange problem

    I installed you plug-in on to this site

    http://blog.circuitprotection.com/blognews/hello

    I am get a strange error the ajax call is returning a 404 error on the ajax call which causes the code to try an run the onError function whitch itself fails funtion die not found

    die is not defined
    [Break on this error] mysack.onError = function() { die( “…mment. Please try again later.” ) };

    Have you any idea as what is causing this?

    Paul

    Report this comment

  10. Arie says:

    I’ve got a feature request. :) It’d be awesome if there was a Cancel option … as in, if someone clicks “Report comment,” and the little text box to explain why they’re reporting pops up, and they realize, “oops! I didn’t mean to report that comment,” they could cancel out.

    This is something Intense Debate does with their report feature, and it’s a great option!

    Report this comment

  11. Travis says:

    I created a jQuery version of this plugin over at the WordPress Support forums: http://wordpress.org/support/topic/366513

    Report this comment

  12. Andrew says:

    Hi, how can i manually insert report comment link into a page?
    can this work with the buddypress plugin?

    Report this comment

  13. SoundsFunny says:

    And one ip can report unlimited number of comments like i just did on ur blog and its easy to spam them with scripts

    so add a captcha option ( make it optional )
    add a option so admin can limit number of reports to one ip address, like a field to submits numbers (3,5,10,15 like this )

    hope it helps and thanks again

    Report this comment

  14. SoundsFunny says:

    well it sounds funny when someone reports editors comments and staff comments, please add a feature to put some users in safe list or add staff in exception list or something like that lol

    take care, thanks for great plugin, just hoping its secure from shell hacks,xss hacks or other vulnerabilities

    Report this comment

  15. Travis says:

    I changed your plugin to place the javascript in wp_footer. One suggestion would be to add a couple do_action’s and apply_filter’s so unappeasable folk like me can mod it from functions.php instead of changing your plugin core :)

    Report this comment

  16. klon says:

    Although now it works, I found a bug (minor one, but still) in it. In “Moderation” panel, under “Commenter’s IP”, it shows actual REPORTER’S IP.

    Also, “Moderation” panel looks quite unergonomically right now. With bigger comments, it breaks display and gets mixed up with Admin Panel’s footer. Maybe it would be a good idea to make it a two column page (FIRST column: date added, commenter’s ip, status and report info, and in the SECOND: the comment itself). It also would be very nice to be able to somehow integrate moderation with comment moderation apnel — be able to mark comments as spam, quick edit them and such. AJAX-powered report viewing would be a nice addition too.

    Anyway, it’s a great update adding lot’s of great functions I’ve been waiting for for a looong time :) Keep up the great work :)

    Report this comment

  17. klon says:

    Hello,
    I’ve installed 2.0 today, and it broke my WP install. After upgrading from 1.0 to 2.0 (plugin was active, and I didn’t know about the need to first deactivate it, upgrade and only then activate again), I got “You don’t have sufficient privileges to upgrade plugins”, and after trying to return to main admin Dashboard — “You don’t have sufficient privileges to access this page”. I had to deactivate all the plugins through MySQL query, and only then WP admin panel returned to normal. Situation repeated after activating the plugin again.

    Report this comment

  18. Boni says:

    Hi Tod, new version conflicts with Role Scoper plugin, and this is the message it is giving.


    Role Scoper cannot operate because another plugin or theme has already declared the function “set_current_user” or forced early execution of “pluggable.php”. All posts, pages and links are currently hidden. Please remove the offending plugin, or deactivate Role Scoper to revert to blog-wide WordPress roles.

    I really need Role Scoper to manage the many roles on my blog. Anyway I could work around this?

    Report this comment

    • Todd Stowell says:

      @Boni – testing a fix right now – will post an update when it is ready.

      Report this comment

    • Todd Stowell says:

      A fix has been made. Download v2.0.2 from WordPress and you should be all set.

      Report this comment

      • Boni says:

        Hi Todd,

        Thanks for the quick fix It is now working and man, this is truly a great plugin and very awesome indeed and I am dying to deploy it on my production site. However, I noticed the issue I raised in my post sometime back is still not resolved. All comments are still being thrown into moderation. What could be happening?

        Report this comment

        • Todd Stowell says:

          @boni – can you email me a screen shot of your settings > discussion screen? I want to see if I can replicate this issue. Also, what other comments / moderation / user management plugins do you have installed?

          Report this comment

          • Boni says:

            Todd, Just send you the screen shots to this e-mail wordpress-cms AT tierra-innovation DOT com

            Report this comment

            • Todd Stowell says:

              @Boni – thanks. It’s hard to tell right off where the issue may be. The plugin itself doesn’t add anything to your comment, so it is unlikely that would cause the issue. It is possible that it could conflict with another one of the plugins, but without having all of them locally to test with, it would be difficult to dissect. Just to clarify, when the plugin is active, your comments go into a moderation queue versus appearing directly on the site?

              Report this comment

              • Boni says:

                Yes, Todd that is correct. I will try it on a new wordpress installation without any plugins and give you feedback

                Report this comment

              • Boni says:

                UPDATE. Works well on a fresh installation. I think I have to test all my 31 plugins installed, one at a time and see which one is causing problems. I will give you feedback.

                Thanks for your wonderful work

                Report this comment

              • Boni says:

                @Todd, I have found the cause of the problem. It is the wordpress’s Comment Moderation option under settings->Discussion. You have a box after the line Hold a comment in the queue if it contains ... I had to have a digit zero (0) to make the plugin work as I wanted. Another thing is I made sure my text area fields for both black list and words to moderate were clear or empty. So I effected this change and everything works now.

                However, I think it would be good to have a list of common bad words and let them not get to the site at all. Now in my current configuration, I let all sorts of words get to the site and rely on people to report them. I think it would be great to have a have some sort of first line of defence of common black listed words and if that is breached, then one can rely on the readers reporting through your plugin.

                Thanks for your great work.

                Boni

                Report this comment

              • Ash says:

                Had same issue and changing 1 to 0 in disscussion page fixed this. Also adding www. to blacklisted words made all url’s become moderated again. Not perfect but problem resolved for now.

                Report this comment

  19. Would it be possible in 2.0+ to let admins decide for themselves where to insert the link instead of automatically inserting it after comment_text.

    Report this comment

  20. Never mind. I figured it out…..
    /Daniel

    Report this comment

    • Todd Stowell says:

      @Daniel Forslund – if you want to send us the changes, we can add them into the plugin and let you set the language. Seems like you’ve already done the translation, so we can certainly roll it into what we have. Thanks!

      Report this comment

  21. I love this feature but no matter what I do I am unable to change the language to Swedish.

    I have changed:

    add_option(‘rc_linktext’, ‘Anmäl överträdelse av kommentarsregler’);
    add_option(‘rc_beforelink’, ”);
    add_option(‘rc_afterlink’, ”);
    add_option(‘rc_success’, ‘Kommentaren är anmäld. Tack!’);
    and

    update_option(‘rc_linktext’, ‘Anmäl överträdelse av kommentarsregler’);
    update_option(‘rc_beforelink’, ”);
    update_option(‘rc_afterlink’, ”);
    update_option(‘rc_success’, ‘Kommentaren är anmäld. Tack!’);

    What am I missing?

    It still shows the english text; Report this comment on the blog and not the swedish; “överträdelse av kommentarsregler’”

    /Daniel

    Report this comment

  22. sundari says:

    I’m trying this out on a MU install of wordpress, and it’s not working at all. Is there something extra I need to do to get it onto the template?

    Report this comment

    • Todd Stowell says:

      @sundari – what version of WPMU are you currently running? While we haven’t tested the plugin on WPMU, it should work with the latest branch release since it now lives within the single user codebase.

      Report this comment

  23. Boni says:

    Hi, This is a great plugin and a must for real if you are running a big website with tons of comments from unregistered users. Thanks for the great and awesome work.

    I have just one issue: when I deploy the plugin, it sends all comments to moderation and I have to go to moderation and start approving comments and usually from there I can see inappropriate comments.

    Reason I want this plugin is because I have a lot of unregistered users that post comments and I want their comments to go straight to the site and if there is any bad comments I want visitors to report them. In the current form, I have to now baby sit the site, which is impossible as the site is active with comments 24/7.

    Is there a way I can turn off the feature that makes all comments go to moderation?

    Boni

    Report this comment

    • Todd Stowell says:

      @Boni – there are settings within WordPress to moderate all comments. In the next version release I have been working on, you can open that and rely on your end users to ‘moderate’ the posts for you. They will then go into a queue which you can review / approve / delete. We should have the next version ready in the coming weeks, so stay tuned.

      Report this comment

      • Boni says:

        Hi Todd thanks for the response and look forward to your next version.

        I think the current version is great too for me and I want to start using it right away. However, the problem I have is that people are able to post comments straight to the website normally without your plugin, but as soon as I enable it, ALL the comments start getting trapped for moderation. When I check wordpress settings in Settings –> Discissions –> Before a comment appears , both check boxes are unmarked, the way I want them, but the comments still go to moderation.

        As soon as I disable your plugin, things get back to normal and people can post comments straight to the site. So it looks like the plugin is causing or activating this moderation and I was wondering where else to disable this. The wordpress settings look disabled alright, but it seems those settings are overridden by your plugin.

        Boni

        Report this comment

  24. jm6tm says:

    thanks but it doesn’t work for me, on click on the report link, nothing…
    why ?

    Report this comment

  25. Good but says:

    Good plugin. I think it should have a capcha or something to prevent users from just pressing each one on each comment.

    Report this comment

  26. Nelson says:

    Greate plugin! thanks !

    Report this comment

  27. Levani says:

    Can I see a demo please?

    Report this comment

    • Jonah says:

      @Levani – Thanks for your interest! I have activated this plugin on our site. You can now see the “Report this comment” link below each comment on this thread as well as others. Feel free to click the link to try it out. Here is an example of the resulting email you will receive when someone clicks the link:

      ===============================================
      A visitor on your site has reported the following comment:

      TITLE: AJAX Report Comments
      URL: http://tierra-innovation.com/wordpress-cms/plugins/report-comments/#comment-121
      Author: Levani
      Date: 2009-12-27 05:38:30

      Comment text:

      Can I see a demo please?
      ===============================================

      Let us know if you have other questions or need more information.

      Report this comment

      • Levani says:

        Thanks for the demo!

        I have one question. I have installed this plugin on my test blog and as I see administrators can only check the reported comments through their email, am I right? What about checking the reported comments directly from the admin panel? I think it would be much better to add, for example, one tab in comments page for the reported comments, where admins would be able to delete the comment or reject the report.

        Besides I’m agree with Good but, once the user clicks on the report comment link there should be some confirmation message appeared, to prevent junk reports. Also I have seen on many websites that users can specify the reason why they think the comment should be reported. Why not give them one field for it? This would be more useful for admins as well.

        Thanks for the great plugin.

        Report this comment

        • Todd Stowell says:

          @Levani – Adding a full admin interface is coming in our next release. I’ll take your suggestions and compile into our feature request list. Thanks!

          Report this comment

        • Todd Stowell says:

          @Levani – we just checked in v2.0 to wordpress which provided a full moderation interface within the WP admin. You can disable email notifications if you like and simply use this instead.

          Report this comment

        • Eva says:

          “once the user clicks on the report comment link there should be some confirmation message appeared, to prevent junk reports.”

          This is exactly what I’m looking for as well. I currently moderate a blog that uses the “Safe Report Comments” plugin, and people are reporting things almost constantly, Every day I need to re-approve several comments that reached their reporting threshold. I’m quite sure that 99% of the reports are not meant to be reports, but just people curiously clicking on the “report” link. I was hoping *this* plugin would have a confirmation option, but don’t see it here either.

          Report this comment

Leave a Reply

Want to receive announcements about the latest plugin releases? Sign up for our email newsletter: