Archive for December, 2005

Email Links Obfiscation with Javascript - Foil the Spam-Bots

Friday, December 9th, 2005

I have found myself telling a lot of people about this simple technique that uses client side (browser) javascript to create clickable ‘mailto:’ links inside your web pages that are difficult to harvest using the typical automated bot technique used by spammers. If you have ever added your email address to a web site only to have it ‘tainted’ by spammers, who pick it up from the site and start sending you a huge volume of spam. The insidious spammers even send message with subjects taken from your site.

So - here is a simple technique that foiled the spammers:

We use a little javascript to write the link into the browser:
(remove the < br / > links added by WordPress)