Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Quick and Simple PHP Honey Pot Spam Prevention (devgrow.com)
4 points by mdolon on July 10, 2010 | hide | past | favorite | 4 comments


A better way of doing this is having the hidden form element named 'email' and the actual email input named something else, as many scripts will be set to auto input based on these submissions


But how does that affect accessibility?

Also, if you do that you need to remember to keep track that the email variable is actually a honey-pot and whatever name you choose is the actual e-mail address.


In terms of accessibility, I assume the label element is more important as the name of the input element isn't visible anyways (for screen readers and people with CSS disabled). I agree with you though, it does seem like a headache to deal with for more complex (or multiple) projects - makes more sense to name the input field something unique that you can easily remember.


That's the way I have set up my websites a few years ago. Never seen a single spam comment since then.

Of course, a determined spammer will overcome these hurdles. But most spam bots don't bother.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: