2
   

NoSpam email javascript link and other no spam tips

 
 
Reply Wed 27 Nov, 2002 05:40 pm
Spammers use harvesters to get emails to add to their lists, thus posting your email on a public webspace has always been the surest way to get spam. Many people have taken to posting their emails in these formats:

Quote:
name AT hotmail DOT com

or


Those tricks are intended to fool email harvesting programs while not fooling humans, but as always some of the humans are fooled too.

Here is a javaascript that compiles the email address on the fly and displays as a regular email link to the end user (as long as they have a javascript enabled browser) but confuses most spam bots.

Code:<script language="JavaScript">
<!--
var name = "name";
var domain = "domain.com";
document.write('<a href=\"mailto:' + name + '@' + domain + '\">');
document.write(name + '@' + domain + '</a>');

//-->
</script>


In the above code you must replace the following red parts (with the blue part of the example emails):
var name = "name"; (e.g. name@hotmail.com

and

var domain = "domain.com"; (e.g. [email protected]hotmail.com )

I will post some even better email cloaking tools in the future.
  • Topic Stats
  • Top Replies
  • Link to this Topic
Type: Discussion • Score: 2 • Views: 12,655 • Replies: 4
No top replies

 
Craven de Kere
 
  1  
Reply Wed 27 Nov, 2002 05:45 pm
If you'd like to use the above script but do not want the link to consist of the compiled email use the following:

Code:<script language="JavaScript">
<!--
var name = "name";
var domain = "domain.com";
document.write('<a class=\"headerlinks\" href=\"mailto:' + name + '@' + domain + '\">');
document.write('Contact' + '</a>');

//-->
</script>


Replace the same parts as in the example in the first post but then also replace the word contact with teh word you want your nospam email link to say.
0 Replies
 
TechnoGuyRob
 
  1  
Reply Sat 5 Apr, 2003 07:40 pm
c++ is better, at least i know it. <grin>
0 Replies
 
Monger
 
  1  
Reply Mon 7 Jul, 2003 09:16 am
what the hell does C++ have to do with this?

Pages like this make me cackle with glee:
http://www.robietherobot.com/spamfight.htm
0 Replies
 
Monger
 
  1  
Reply Mon 18 Aug, 2008 10:00 pm
@Craven de Kere,
My typical solution these days is to just mix some numeric character references and/or character entity references into the email address source, e.g. href="mailto&#x3A;me&#64;my.com". No JavaScript requirement, no negative side effects, still easily readable even in the source, but much less spam. Sure, it's much easier to write a harvester that can deal with this than one that understands JavaScript, but it works well enough for my needs.
0 Replies
 
 

Related Topics

 
  1. Forums
  2. » NoSpam email javascript link and other no spam tips
Copyright © 2019 MadLab, LLC :: Terms of Service :: Privacy Policy :: Page generated in 0.03 seconds on 10/17/2019 at 04:02:36