Little Antispam function
-
Today I have many commentspam. The spambot used ascii in the author field. I think it would be important to control if it use in that field and when its true the comment shouldn’t insert into the database. What would you say?
// Insert to stop spambots which use ASCII
if(ereg("&#", $author)) die( "Stop spamming my Blog!" );
The spambot used that:
&# 111;nl&# 105;n&# 101; pok&# 101;r
Normally its whitout a space between # and the number.I have make a little check for that, and if &# in the field I stop with a die().
I insert it in funtions-post.php at line 456 before
if ( check_comment($author, $email, $url, $comment, $user_ip, $user_agent, $comment_type) )
@developers:
What do you think about a check like that?I hope that you understand my english. ??
– bjoern
- The topic ‘Little Antispam function’ is closed to new replies.