![]() |
January 14, 2003Fighting SpammersNoticed that some bloggers are using Javascript to hide the mailto: tags from spammers, but still enable users to click on a link which a browser thinks is a mailto: anyway. For example, here's the code from the homepage of Adam Medros's blog (which, by the way, I've begun regularly reading -- he's a grad student blogging his experience at Harvard Business School).Instead of the a href mailto code in the HTML, there's a javascript:goForth() function call. The function looks like this: function goForth(c,n,d) { c += ' '; var length = c.length; var number = 0; var bar = 0; var answer = ''; for(var i = 0; i < length; i++) { number = 0; bar = 0; while(c.charCodeAt(i) != 32) { number = number * 10; number = number + c.charCodeAt(i)-48; i++; } answer += String.fromCharCode(decrypt(number,n,d)); } // Updated security feature parent.location = 'm'+'a'+'i'+'l'+'t'+'o'+':'+answer; }And the mailto invocation inside the A HREF looks like this: javascript:goForth("79 492 121 428 518 506 455 100 156 287 518 518 71 437 518 79",629,461) Very interesting.
UPDATE 30 Jan 2003 --- Finally found the author and more details on this
Javascript code. It's called Email Protector and the link has everything you need.
Posted by brian at January 14, 2003 03:25 AM
Comments
Read More in the Archives:
November 2004 | October 2004 | September 2004 | August 2004 | July 2004 | June 2004 | May 2004 | April 2004 | March 2004 | February 2004 | January 2004 | December 2003 | November 2003 | October 2003 | September 2003 | August 2003 | July 2003 | June 2003 | May 2003 | April 2003 | March 2003 | February 2003 | January 2003 | December 2002 | November 2002 | October 2002 | September 2002 | August 2002 | July 2002 | June 2002 | May 2002 | April 2002 | March 2002 | February 2002 |
brianstorms is Brian Dear's weblog. Non-spam email:
Be sure to take a look at these other fine websites:
Copyright 2002-2003 Birdrock Ventures.
brianstorms is a trademark of Birdrock Ventures.
|