Forum Moderators: open
Anyone have any advice? I've been looking for server side solutions but most of them are intertwined with Javascript and CSS.
Thanks!
Spam protection...
- Very strict and verbose validation of the comments field? HTML, BBCode, URLs, keywords...? Although that would no doubt block a few legitimate comments along the way!
- Ask a simple (random) question... "What is one plus two?"
- Or, even a very simple question... "If you are a robot, tick this box [ ]" ...?
The last option I can't use because it's unprofessional (client would say: why do we have this?), but the textual captcha is a GREAT idea. Thanks for that!
No, I mean that I can't use the usual way of making an input field display:none so that a human won't see it but a bot will try to fill it in because on many phones, including Blackberrys, it'll display that field and it looks ugly.
Ah ok, so CSS to hide an INPUT is being ignored? What about if that INPUT is inside a DIV and you hide the DIV? Or are INPUTs just unhide-able on the Blackberry?!
This is because once your form URL is discovered, the robots post directly to that form processor, never visiting the form again. So again, CSS and JS are out of the picture.
I can't use the usual way of making an input field display:none
But can you make an input type of hidden? Some bots will pick this up but most won't.
<input type="hidden" name="mail-to" value="">
As said, this has limited success but in combination with other things in your form processing script is a good tool in the arsenal.
Generate the form dynamically, add a hidden field with a random number in it. Think of the number as a sessionID. Keep server-side a timestamp when it was generated.
When processing forms, don't act on sessionIDs that are too old.
Check server side for keywords, for bbcode or html links, don't use it if it contains that.