Email Addresses in Web Pages

You want to give your site's visitors a way to contact you by email but don't want your emali address to be abused. Here are a few ways to protect your email address when building your website.

1. Use defined users and filters

Don't use the catch all email facility. Instead define users such as enquiry@ or sales@. It's better if you can avoid the most obvious ones like info@ as some people might speculatively try these. It's best to use a person's name which does not appear elsewhere on the site.

Most email providers or email software offer you filters to use on incoming email. You define a parameter in the email and then filter out any incoming mail which does not contain it. For example, you could set your email link as mailto:info@companyname.com?body=security%20code%20123%20 (please%20leave%20intact%20in%20message%20body) then filter out any mail which does not contain the text "security code 123". Please note that a space is replaced by "%20" ni the mailto parameter.

This will prevent email from automated systems but you could miss out on genuine mail if the sender fails to understand this measure. Be sure to explain it well on your contact page.

It is important when using filters on an address that you don't use this address to send other mail as your replies could be filtered out. Keep one address purely for email from your website.

2. Use a form

Use a form for your site's visitors to contact you. This hides the email address in the browser but it may still appear in the HTML coding. If it does yuo can get around this by defining a subject line, e.g. info@companyname.com?subject=enquiry and filtering out all incoming mail which does not have this subject line.

3. Use JavaScript for links

It is possible to write the text link in JavaScript instead of HTML. The script breaks the email address down into its elements and then puts it back together. It appears just as a normal HTML link in the browser even down to the way it appears in the browser's status bar. This method keeps everything looking as the visitor would expect but protects your address from Spam harvesters, programs designed to crawl sites and find mailto links in the code.

Copy this code replacing the 4 variables user, domain, extension and link with your own information. This example uses the made up email address info@companyname.com. It should be obvious which parts to change and to what.

[script language="JavaScript" type="text/javascript"][!--

var user = "info";
var domain = "companyname";
var extension = "com";
var link = "Email Us";

document.write('[a href="mailto:' + domain + '.' + extension + '"]'); document.write(link + '[/' + 'a]');
// --][/script]

Please note that the square brackets must be replaced with angled brackets for the script to work. The square brackets are merely to enable me to display the coding here.

Chris Smith is a full time web developer building websites for small businesses and individuals.

Please visit his site to see live examples of these techniques in action and for further information on web design and development.

web development | web development

quick home cleaning Northbrook ...
In The News:

Citi's updated banking agreement warns that actions by third-party AI agents may be treated as authorized by you, even after a hack leaks your credentials.
Uber Kids lets children as young as 10 ride alone in a pilot across Austin, Nashville and Madison, with live video, PIN verification and RideCheck alerts.
Kurt "CyberGuy" Knutsson explains why stolen data can resurface years after a breach, plus tips on free credit freezes and password managers.
Sean Duffy flew a $148,000 Jetson One solo over NASA's Kennedy Space Center. Two days later, five eVTOLs flew in formation at a public airshow.
Stay up to date on the latest AI technology advancements and learn about the challenges and opportunities AI presents now and for the future.
An AI bionic eye trained on a blind man's brain responses helped UC Santa Barbara researchers produce more predictable phosphenes with less current.
A researcher claims Google Gemini pulled private Gmail billing details into chats, and Google confirms some connected-app data may face human review.
Housefishing scams use AI real estate photos to fool buyers. Google Lens reverse image search and live video walkthroughs can help expose the fakes.
Data brokers may expose your name, home address and phone number to scammers sending fake USPS delivery texts ahead of the Black Friday shopping rush.
Remus Stealer malware developers claim Gmail access survives a password change, but Google says the attack targets infected devices, not a Gmail flaw.
Palmer Luckey says SLAB, his floating industrial city, would last 1,000 years, hosting metal processing and oil refining beyond California rules.
United Airlines is blocking unauthorized AI travel agents from its booking systems, warning that automated purchases could put MileagePlus miles at risk.
Apple's macOS 27.3 beta 2 adds new Mac security controls for AI agents, letting you pick specific protected folders instead of granting Full Disk Access.
Google's AI used smartwatch sensors to spot hypertension without a blood pressure cuff, but the Nature study found it missed about 1 in 3 cases.
The FBI warns the ARTEX AI hacking tool can give criminals privileged access in under three hours, targeting Microsoft 365 and financial firms.
The FDA-authorized Virtuoso Endoscopy System uses needle-sized robotic arms to remove bladder tumors intact, helping pathologists assess detrusor muscle.
Identity theft restoration involves credit freezes, fraud alerts and disputing fraudulent records. Here's how the recovery process works, step by step.
Genesis AI raised $500 million to expand its general-purpose robot Eno, which learns physical skills from workers wearing special electronic gloves.
JPMorgan Chase says hackers accessed marketing data at third-party vendors as an extortion group leaks records tied to Visa and Mastercard customers.
Uber Parking launches in 15 U.S. cities after the SpotHero deal, offering upfront prices, Uber One credits, and a future role for robotaxis in garages.
The Fox News AI Newsletter covers the latest artificial intelligence technology advancements, including the challenges and opportunities AI presents now and for the future.
Microsoft Outlook flaw CVE-2026-124194 lets a malicious .msg file expose NTLMv2 authentication data, and Microsoft confirms hackers already exploited it.
Former Secret Service cyberfraud investigator Jason Brown warns AI voice cloning scams could trick families into losing thousands of dollars this holiday season.
A single data broker opt-out may not be enough. Spokeo, Whitepages and BeenVerified can still expose your address and family details to scammers.
Apple Photos now embeds an invisible SynthID watermark in images edited with Apple Intelligence tools like Clean Up, Extend and Reframe in iOS 27.2.

Newsletter Management Using PHP w/o mySQL for Beginners

Let's begin by setting some limits. If you're like me,... Read More

If Its Done Its Done for: Make Your Website Part of Your Business before You Build

Web sites are an Ongoing Part of Business.All too many... Read More

The Web: Your Window of Opportunity

Thinking about starting up a business? The web is the... Read More

Free Websites & Why You Should Avoid Them

It amazes me how many people try to build serious... Read More

Make Your Web Site User-Friendly!

Making a web site is easy. Making a good web... Read More

7 Ways to Gain a Professional Online Reputation

A professional online reputation is essential to the flourishing of... Read More

What ROI You Should Expect From Your Web Site

Is Your Web Site an Expense or an Investment?Why don't... Read More

What YOU Should Know Before Getting A Web Site!

Everyday thousands of new businesses make the leap and take... Read More

Guide to Internet Business - Website Setup

After planning the design and content of your website, it's... Read More

Content Management ? The New Standard in Web Design

The evolution of web development parallels the model of technology... Read More

Autoresponders Make You Look Like A Pro

People like to get immediate responses to requests. Autoresponders are... Read More

Freelance Programming is Easy to Manage

There are several reverse bid freelance sites out there. Beyond... Read More

Eight Deadly Web Site Mistakes and How to Avoid Them

Creating and maintaining an effective presence on the Web has... Read More

Why You Need a Website

You hear a great deal about the Internet these days... Read More

12 Tips To Great Websites

Why do some sites succeed while the vast majority of... Read More

Do This One Thing to Create a Powerful Product-Selling Web Site

Spend time planning your Web site. Before you design a... Read More

1 Simple Solution to All Internet Marketers about Their Website Design Needs

It is an undeniable fact that not everybody is keen... Read More

Content Management

More and more businesses are recognizing the importance of content... Read More

Having a Domain Name And Web Site Gives Your Business The Key To The Door

Just like all things in life, the ways to run... Read More

Should You Design Your Own Website?

If you're anything like most small business owners, you probably... Read More

Your Future Profit Is In The Stars

You don't believe in astrology but you check your horoscope... Read More

Why Is No-one Buying From My Website?

Are you, like many other website owners, frustrated at the... Read More

6 Steps To Your Own Website

A lot of people these days are interested in getting... Read More

Why Your Brick-and-Mortar Biz Needs A Website

The internet has taken over our lives with a vengeance,... Read More

7 Golden Rules For Building Mini Sites

First, an eye opener. Making your fortune through affiliate programs... Read More

professional home cleaners Wilmette ...