Web Hosting

Singapore Web Hosting

With 24/7 Super Support
Web Hosting Singapore Blog    Web Hosting Singapore Contact Us    Web Hosting Singapore Client Login
Singapore Dedicated Web Hosting
Email: Call: +65 6288-6264
 
Support Center » Knowledgebase » How to protect your email from spambots?

Web hosting Knowledge Base/FAQ

 How to protect your email from spambots?
Solution

Are you protecting your email addresses?

Spammers get your email address by using evil automatic software that scours your website. When they find something like "mailto:joe@YourDomain.com", they put you on their spam lists. These software are known as "spambots".

Techniques for avoiding the spambots have been around for years, but it's surprising how many webmasters aren't using them.

To protect your email addresses, here's a simple bit of code that robots won't be able to harvest, at least with their current techniques:
<script language=javascript>
<!--
var linktext = "THIS APPEARS ON THE PAGE"
var email = "sarah"
//replace sarah with your email username
var emailHost = "YourDomain.com"
//replace YourDomain.com with your domain name
document.write("<a href=" + "mail" + "to:" + email + "@" + emailHost+ ">" + linktext + "</a>" )
//-->
</script>

If you want to show your email address, use this instead (do not use the above codeĀ and replace the linktext with your email address):
<script language=javascript>
<!--
var email = "sarah"
//replace sarah with your email username
var emailHost = "YourDomain.com"
//replace YourDomain.com with your domain name
document.write("<a href=" + "mail" + "to:" + email + "@" + emailHost + ">" + emailĀ  + "@" + emailHost+ "</a>" )
//-->
</script>

Put this code on your pages, making sure to replace all instances of your old "mailto" HTML code.

Some other ways to protect your email:

  • Image to display your email
  • Use online form submission


Article Details
Article ID: 50
Created On: 04 Apr 2008 11:45 AM

 Back
 Login [Lost Password] 
Email:
Password:
Remember Me:
 
 Search
 Article Options

 

Singapore Web Hosting With A Difference - Click To Read More...
Singapore Web Hosting With A Difference - Click To Read More...