HTML Tutorial


 Forum HomeForum Home   FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
RegisterRegister - Not registered yet? Got something to say? Join HTML Code Tutorial!
How do I create an email link?
Post new topic   Reply to topic    HTML Help Forum Index -> HTML FAQ
View previous topic :: View next topic  
Author Message
mjpliv



Joined: 11 May 2004
Posts: 406
Location: Nova Scotia

PostPosted: Sat Jun 05, 2004 4:17 pm     How do I create an email link? Reply with quote

The mail link works with the same <a> tag as other links in your HTML. A mail link looks like this -

Code:
<a href="mailto:mjpliv.eastlink.ca">Send me some mail!</a>


Clicking on the words "Send me some mail!" would activate the default mail client on that person's computer opening a new email message with the destination address already filled in. You can also have the subject line filled in using this code.

Code:
<a href="mailto:mjpliv.eastlink.ca?subject=Put text here that you want in the subject line">Send me some mail!</a>


Or you can send a copy to another recipient.

Code:
<a href="mailto:mjpliv.eastlink.ca?cc=anotehraddressatasite.com">Send me some mail!</a>


Or perhaps a blind copy.

Code:
<a href="mailto:mjpliv.eastlink.ca?bcc=anotehraddressatasite.com">Send me some mail!</a>


You can fill in the body portion of the message as well.

Code:
<a href="mailto:mjpliv.eastlink.ca?body=This is cool!">Send me some mail!</a>


If you want these can be combined

Code:
<a href="mailto:mjpliv.eastlink.ca?subject=a message for you&cc=anotehraddressatasite.com&body=Hello!">Send me some mail!</a>


One thing to remember is that every time you list your email address on a website you increase the chances of it being harvested by a web crawler. These crawlers are released to gather as many valid email addresses as possible to add to spammer's mailing lists.

Some sites, like this one, hide your email address inside a database that is not part of the website. If you do not have access to this function you can mask your address by using unicode. There are online services to create this code, or you can download one from http://www.codefoot.com/software/ecloaker/index.html (There are few pop-ups on this page I am afraid).
Display posts from previous:   
Post new topic   Reply to topic    HTML Help Forum Index -> HTML FAQ All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
HTML Help Archive
Powered by phpBB © 2001, 2005 phpBB Group
 
HOSTING / DESIGN
MAKE MONEY

Home
  |   Tutorials   |   Forum   |   Quick List   |   About
Copyright ©1997-2002 Idocs and ©2002-2007 HTML Code Tutorial