You have probably all seen the Comment Queue hack over at scriptygoddess. Well, a couple nights ago Cheyenne asked me to install it for her, as she has been having troll problems lately.
The Comment Queue script requires PHP and a MySQL backend and gnome-girl.com is not using a MySQL backend. Needless to say, it would be a chore and then some to migrate her site to MySQL. So, as you may have heard if you read her site, I quickly threw together a perl version for her to use, and I thought I would release it to the general public now. The interface leaves a little (okay, quite a bit) to be desired, but it works.
So, if you want to use it, after you perform the changes to the MT files and database (only if you are using MySQL) as described in the hack, just download one of the following files, unpack it, and place mt-comments-pending.cgi in your base MT directory. Be sure to chmod it to 755 so it can be executed.
my hero :)
Answer to a prayer -- there's a lot of MT sites that were hit by some auto comment-spam tonight, and this script might be seeing a lot of traffic soon :)
There's one feature you don't mention, and I wonder if it is even possible (not being very intimate with MT internals): Could it insert some URL into the blog-owner notification email where, if clicked, it would confirm or reject the comment? Going to a list has it's uses too, but I most often get isolated comments and a one-click solution would be easier to manage.
For a really fancy wishlist item, I would love to see an email sent to the comment author as well, with the same confirm/reject URLs in the message; this way, if I am on the road, people can still comment to my blog, but I'll be assured they are using a valid email address.
Dave, thanks for creating this script! My weblog got comment spam, and after a few hacks (I use postgres at the back-end, so I modified the tables necessary) I got your script to work! Sweet!
Thanks!! I needed this. I suppose I should take it as a compliment that my site is now a target. BTW, I wrote up some instructions for installing this that some folks may find helpful ( http://www.idblog.org/archives/000329.html ).
Now any ideas for getting [MTComments lastn="8"] to stop returning unapproved comments?
Just thought I'd let you know that on my site mt_comments_pending.cgi showed "No comments pending." always until I changed
my @comments = MT::Comment->load ({ entry_id => '0' }) or return $html."
No \
";pending comments found
to
my @comments = MT::Comment->load ({ entry_id => '' }) or return $html."
No \
";pending comments found
and then it worked. I don't know why (it does say entry_id('0') in Comments.pm), but I thought of it after I noticed that the id= field in the URL line was always id=& rather than id=0& as it should have been.
I've just made two changes to the script that I think are useful. First, I swapped the order of the buttons so that it was easier to click the delete button (it's always in the same place...the button on the right shifts based on how wide the first column is). Second, I added a "Deny All" function, which is very helpful when you get auto-spammed.
My perl is very rusty, so I'm sure this could have been coded better, but as they say, it works for me...you're mileage may vary :).
See http://www.idblog.org/archives/000477.html