internet.com

Go to WebDeveloper Home


hm-v6-139x61.gif

Database Journal: The Knowledge Center for Database Professionals

find a web host with:
CGI Access
DB Support
NT Servers
UNIX Servers
Telnet Access

advanced search
jobs

Get FREE Development Info via your Email!

The Webdeveloper channel
FlashKit
GIF.com
HiermenusCentral
webdeveloper Jobs
Java Boutique
JavaScript.com
JavaScript Source
ScriptSearch
StreamingMedia World
WDJ
WDVL
WebDeveloper.com
WebReference.com
XMLFiles.com

internet.com
Internet News
Internet Investing
Internet Technology
Windows Internet Tech.
Linux/Open Source
Web Developer
ECommerce/Marketing
ISP Resources
ASP Resources
Wireless Internet
Downloads
Internet Resources
Internet Lists
International
EarthWeb
Career Resources

Search internet.com
Advertise
Corporate Info
Newsletters
E-mail Offers

internet.commerce
Be a Commerce Partner










D R .   W E B S I T E®
WebDeveloper.com

March 29, 1999

The Ultimate Answer to the Spam Problem

By David Fiedler and Scott Clark
Dear Dr. Website®: How can I hide e-mail addresses from spammers, while still including them for legitimate users of my site?

We promise -- this is the last thing we'll have to say on this subject, mainly because, thanks to a number of readers, we believe we have the ultimate answer (or answers) to this problem...and we thought it couldn't be done!

The first solution is most suitable for people who like to mess with HTML code, work alone (anyone else, seeing this in your HTML, would probably fire you because it looks so ugly), and can dig it -- don't try this with FrontPage!

Courtesy of the people at SiteUp Networks is the Mailto Encoder, which will convert your real e-mail address to HTML that looks like this:


wdstaff@in
ternet.com

This is simply hard coding for the characters, similar to using ® as a substitute for ® (the "registered" mark). While the code that SiteUp mails you will look fine in a browser and work as a mailto: when someone clicks on it, it will not look anything like an e-mail address to a spammer.

Spammers comb HTML page source with robots looking for addresses of the form foo@bar.com (hope they try to send to that one!), and obviously they won't be able to do much with addresses coded this way unless they visit every Web page by hand (come to think of it, that would be an ideal punishment for a spammer...).

The second solution uses JavaScript, and even if you're not a programmer, you should be able to handle this one. Basically, the code keeps the mailto:, your name, and your domain separate in the HTML file, combining them only when the page is browsed. It's a little bigger in size than the previous solution, but quite clean and it will even work with FrontPage:


<script language=javascript>
<!--
// SpamProof Mail Script 1.0 by Joseph McLean <flux@thecentre.com> - freeware
// Linktext is the text you want folks to see and click upon.
// email1 & email2 are the text on either side of your email address's @ sign.

var linktext = "Dr. Website"; var email1 = "webdoc"; var email2 = "iw.com";

document.write("<a href=" + "mail" + "to:" + email1 + "@" + email2 + ">" + linktext + "</a>") //--> </script>

A similar -- and even simpler -- script is JavaScriptSource's Email Protector.

Special thanks to our friends at the City of Kalamazoo, Mich., and Mitre for turning us on to these solutions.


Visit The Dr. Website® Archives.
Click here for a list of Dr. Website's most frequently asked questions (and answers!).
Send your own question to Dr. Website®.

Fast Jump to Anywhere on WebDeveloper.com®:


Contact the WebDeveloper.com® staff

Last modified: 20

 

Refresh Daily
Join Editor-in-Chief David Fiedler The Editor With No Time and find truth, justice, and a clue or two.


Browse by Category
[ Site Map ]

ActiveX / VBscript
Animated GIF Archive
Browsers
CGI / Perl
Database Connectivity
E-Commerce
HTML-Advanced: DHTML, CSS
HTML / Site Authoring Tools
Intranet/Groupware
Java
JavaScript
Multimedia: Audio / Video / Streaming Technologies
Opinions
Refresh Daily: Editorial Column
Security
Servers & Server Tools
Site Design / Graphics
Site Management / Marketing / Log File Analysis
VRML / 3D
XML




JupiterOnlineMedia

internet.comearthweb.comDevx.commediabistro.comGraphics.com

Search:

Jupitermedia Corporation has two divisions: Jupiterimages and JupiterOnlineMedia

Jupitermedia Corporate Info


Legal Notices, Licensing, Reprints, & Permissions, Privacy Policy.

Advertise | Newsletters | Tech Jobs | Shopping | E-mail Offers

Solutions
Whitepapers and eBooks
Intel PDF: Virtualization Delivers Data Center Efficiency
Intel eBook: Managing the Evolving Data Center
Microsoft Article: BitLocker Brings Encryption to Windows Server 2008
Symantec eBook: The Guide to E-Mail Archiving and Management
Microsoft Article: RODCs Transform Branch Office Security
Go Parallel Article: James Reinders on the Intel Parallel Studio Beta Program
Avaya Article: Advancing the State of the Art in Customer Service
Adobe Acrobat Connect Pro: Web Conferencing and eLearning Whitepapers
Avaya Article: Avaya AE Services Provide Rapid Telephony Integration with Facebook
Go Parallel Article: Getting Started with TBB on Windows
HP eBook: Storage Networking , Part 1
MORE WHITEPAPERS, EBOOKS, AND ARTICLES
Webcasts
Intel Seminar: Efficiencies in Hardware/Software Virtualization
HP Webcast: Disaster Recovery Planning
Go Parallel Video: Performance and Threading Tools for Game Developers
HP Video: StorageWorks EVA4400 and Oracle
HP Webcast: Storage Is Changing Fast - Be Ready or Be Left Behind
MORE WEBCASTS, PODCASTS, AND VIDEOS
Downloads and eKits
IBM TCO eKIT: Your IT Budget is Under Attack, Get in Control
IBM Energy Efficiency eKIT: Learn How to Reduce Costs
30-Day Trial: SPAMfighter Exchange Module
Red Gate Download: SQL Toolbelt and free High-Performance SQL Code eBook
Iron Speed Designer Application Generator
MORE DOWNLOADS, EKITS, AND FREE TRIALS
Tutorials and Demos
Microsoft Article: Silverlight Streaming--Free Video Hosting for All
Featured Algorithm: Intel Threading Building Blocks - parallel_reduce
HP Demo: StorageWorks EVA4400
MORE TUTORIALS, DEMOS AND STEP-BY-STEP GUIDES