WordPress – Give your SPAM comments a good kick!

Version: 1.1a
Revision: 34 Build 11

Wordpress – Give your SPAM comments a good kick!


In this tutorial, we are going to use SQL commands to delete all spam comments and approved comments which are no longer needed. However, these source were only written for WordPress users. Therefore, I would recommend you to stay away from this script, if you haven’t got WordPress.

Deleting comments in your “Admin Panel,” it can be frustrating, if you have a lot of SPAM and BULK comments. So, the only way to flush these hordes (messages) from your SPAM box and your Moderation box, then you will have to use these commands. To use these scripts, you will have to click on “phpMyAdmin”.

DELETE FROM wp_comments WHERE comment_approved = 'spam';

Code lists
——————–
0 = Comment Awaiting Moderation
1 = Approved Comment
spam = Comment marked as Spam

Now, if you don’t want to keep these maniacs in your moderation queue / spam box, then, I would advise you to use these PHP source. However, you must place this script inside your “function.php” directory for it to work.

<?php
function verify_comment_referer() {
    if (!wp_get_referer()) {
        wp_die( __('You cannot post comment at this time,
as you will need to enable referrers in your browser.') );
    }
}
add_action('check_comment_flood', 'verify_comment_referer');
?>

Copyrighted By Lair360

Comments are closed.