NYCPHP Meetup

NYPHP.org

[nycphp-talk] stopping comment spam with PHP

Paul A Houle paul at devonianfarm.com
Tue Jun 2 16:38:34 EDT 2009


Konstantin Rozinov wrote:
> Hi guys,
>
> I'm interested in hearing what kind of classes, packages, solutions
> the professionals on this list use to protect their sites against spam
> in relation to comments.
> For example, users commenting on other user's pages like Facebook or
> any social networking site.
>
>   
    No matter what technological measures you use,  you'll need a user 
interface to make hand edits.  For instance,  my site at

http://spoonriveranthology.net/

    uses Disqus for comments because I didn't have time to develop a 
good commenting system for that site.  Disqus is a service that runs on 
a central server that transcludes comments into your site with 
Javascript:  it gives you a pretty decent threaded commenting system 
with an admin UI,  spam defense and other good features.  There's a 
similar service from IntenseDebate,  which is also pretty good...  I 
just picked Disqus because I had to pick something.

    When I first made that site,  I had a comment system that was packed 
as a symfony plug-in.  I had a battle with a spammer:  I found it easier 
to delete his crap with the SQL monitor than with the UI that came with 
the comment system.  I managed to stop him by filtering on certain words 
and blocking any attempt to post links,  but it wasn't a good answer.

    Recently I switched to Disqus comments.  This has increased the 
average # of pages per visit on the site from 8 to 10.  It took about an 
hour to Disqus.

    Today,  the main problem is that that site appeals to a teen 
audience.  Some of the comments are brilliant,  but some are absurdly 
stupid and I delete them to keep the discussion readable.

    I was able to get Disqus integrated with my site in about an hour.  
Disqus has a good API for getting your comments in and out, so it's not 
a roach motel like the Facebook or Google Friend Connect Comments.  I 
could import my old comments into Disqus,  but I haven't gotten around 
to it.



More information about the talk mailing list