Many spambots roam the Internet for email addresses to send massive advertising or to perform phishing attacks. Websites with plain HTML-codes are a favourite target of these bots. But there is a way to make your e-mail address accessible and allow visitors to send you a E-Mail. The visitor’s browser must have enable JavaScript. Here is the code to show a simple E-Mail in HTML-document.
<BODY>
...
<SCRIPT TYPE="text/javascript">
document.write('john' + '@' + 'doe.net')
</SCRIPT>
...
</BODY>
You can also use JavaScript to write a E-Mail link:
<BODY>
...
<SCRIPT TYPE="text/javascript">
document.write('<a href="mailto:john@adoe.net">Email me</a>')
</SCRIPT>
...
</BODY>
The string ‘@’ replaces the @-symbol. With an E-Mail Obfuscator you can encrypt the hole string:
<BODY>
...
<SCRIPT TYPE="text/javascript">
document.write('mailto:j
ohn@doe.net')
</SCRIPT>
...
</BODY>
Compete paranoids can generate a key to mask their E-Mail with an key-mask and encrypt them directly in their site:
<BODY>
...
<script type="text/javascript" language="javascript">
<!--
// Email obfuscator script 2.1 by Tim Williams, University of Arizona
// Random encryption key feature by Andrew Moulden, Site Engineering Ltd
// This code is freeware provided these four comment lines remain intact
// A wizard to generate this code is at http://www.jottings.com/obfuscator/
{ coded = "we9i@uef.ifk"
key = "KE2iJqpaz8Vu0T3othAGWIsgcFmek9ljBPrLyD1fQXOwUC4MY6HvbnZ7NRxS5d"
shift=coded.length
link=""
for (i=0; i<coded.length; i++) {
if (key.indexOf(coded.charAt(i))==-1) {
ltr = coded.charAt(i)
link += (ltr)
}
else {
ltr = (key.indexOf(coded.charAt(i))-shift+key.length) % key.length
link += (key.charAt(ltr))
}
}
document.write("<a href='mailto:"+link+"'>Email me</a>")
}
//-->
</script><noscript>Sorry, you need Javascript on to email me.</noscript>
...
</BODY>
Use this Anti-Spam Email Link Creator create your key
I hope you find your solution to protect your E-Mail.
Greetz
Vali