Spam Karma 2 Plugin for Automatic Deletion

in the early afternoon on Sunday, the 6th of July 2008 by Chad

Lots of folks running WordPress run the excellent Spam Karma 2 plugin from Dr Dave.  I’ve been running it for years and it just works great.

The one issue I have is that for comments with a karma score below anything possibly not spam, I don’t even want saved in the first place.  Most spam scores well below -50 and I don’t even want to see it.

So… I wrote a plugin!!!

Simply download here, saving as sk2_death_plugin.php.  (not phps, watch that extension!)

Upload to your /wp-content/plugins/SK2/sk2_plugins/ folder on your WordPress website.

Open your WordPress admin panel, and go to Manage / Spam Karma 2 / General Settings. Scroll down to the Treatment Plugins Settings, and set the minimum value that you’d accept as even worth checking.  It defaults to -25 which is pretty unlikely to ever get a false positive in my opinion.

image

Anyways, this is unsupported of course, use at own risk, etc.  I don’t have logging quite working right yet but any improvements you have just let me know.

[del.icio.us] [Digg] [Facebook] [MySpace] [Sphere] [StumbleUpon] [Technorati] [Windows Live] [Email]
1 Star2 Stars3 Stars4 Stars5 Stars
(1 votes, average: 5 out of 5)
Loading ... Loading ...

Related Posts

11 Responses to “Spam Karma 2 Plugin for Automatic Deletion”

  1. Chad Says:

    this is a test of the antispam system!

  2. Jeremy Says:

    Ooooooh!

    I’ve had the exact same gripe with SK2.

    Consider me a Beta User.

  3. Chad Says:

    Sweet…
    In my limited testing today it seems to work just peachy.
    I added the BB style URL:
    [ u r l =
    to my blacklist in Spam Karma, with a weight of 1000.
    Used that in testing and it would throw responses with it right over the limit.
    But yeah, even though I don’t even really ever see the spam, it kind of offends me that they show up at all!

  4. Jeremy Says:

    What type of Blacklist do you put the [url = string under?

    The only one that kind of makes sense is Regex Content Blacklist.

  5. Chad Says:

    That’s the one. I used as the string:

    /\[url\=/

    That’s the “proper” regex to use I guess…

  6. Jeremy Says:

    Any idea what would cause this error:

    Warning: Cannot modify header information - headers already sent by (output started at /usr/home/jrgilby/public_html/wp-content/plugins/SK2/sk2_plugins/sk2_death_plugin.php:30) in /usr/home/jrgilby/public_html/wp-includes/pluggable.php on line 694

    It appears to the user as a commnet is posted. The comment does post, but the user has no idea until they refresh the page.

  7. Chad Says:

    looks like there’s extra spaces or line feeds outside the < ?php and ?> tags.
    I hate that…
    But if you go to the Spam Karma general settings, do you see the control panel for it? Or does it error there also?

  8. Jeremy Says:

    Yes. That looks like it was it.
    ONE SPACE after the close tag.

    I hate that too.

  9. Jeremy Says:

    FYI: I just got this error posting a comment here:

    Regex ID: 17563 (*\\[url\\=*) appears to be an invalid regex string! Please fix it in the Blacklist control panel.

    Warning: Cannot modify header information - headers already sent by (output started at /home/pking/public_html/wp-content/plugins/SK2/sk2_util_class.php:208) in /home/pking/public_html/wp-comments-post.php on line 75

    Warning: Cannot modify header information - headers already sent by (output started at /home/pking/public_html/wp-content/plugins/SK2/sk2_util_class.php:208) in /home/pking/public_html/wp-comments-post.php on line 76

    Warning: Cannot modify header information - headers already sent by (output started at /home/pking/public_html/wp-content/plugins/SK2/sk2_util_class.php:208) in /home/pking/public_html/wp-comments-post.php on line 77

    Warning: Cannot modify header information - headers already sent by (output started at /home/pking/public_html/wp-content/plugins/SK2/sk2_util_class.php:208) in /home/pking/public_html/wp-includes/pluggable.php on line 770

  10. Chad Says:

    yeah, it was doing something weird with my [url=blah] detection code

  11. Chad Says:

    OK, for all those interested, the Spam Karma 2 content blacklist regex to block the URL spammers:

    / \ [ u r l = /

    Looks just like that only with no spaces. I give it a value of 1000 just to make sure it gets kicked.
    BTW, new version is out that only runs when the comment is posted and is skipped during other runs.

Leave a Reply

I didn't expect her to counter my plan with nakedness.

-- Riff

Recent Posts

    Poll

    For the Holidays-
    View Results

Search

Captain's Logs

The Sites

Syndication

Stats

  • Comments: 3476
  • Pingbacks: 49
  • Trackbacks: 172
  • Comment Spam: 67448
View blog authority