HTML and CSS Reference
In-Depth Information
Notice that the spaces in the message body This is a test message have been
replaced with the %20 character code. This is necessary because URLs cannot contain
blank spaces.
Although the mailto protocol is not technically an approved communication protocol,
it is supported by almost every Web browser. However, note that a user's browser may
not automatically access Web-based mail clients, such as Hotmail or Gmail, when the
user clicks an e-mail link. End users accessing their mail from a Web-based mail client
must confi gure their browsers to automatically open those Web sites in response to a
mailto link.
Gerry wants you to add a link to his e-mail address on the CAMshots home page. This
will give people who view his site the ability to contact him with additional questions
or ideas.
To link to an e-mail address on Gerry's home page:
1. Return to the home.htm file in your text editor.
2. Go to the first paragraph and locate the text contact me .
3. Mark contact me as a hypertext link using the following code, as shown in
Figure 2-42:
<a href=”mailto:ghayward@camshots.com?subject=CAMshots%20Message”>
contact me
</a>
Figure 2-42
Linking to an e-mail address
e-mail address
e-mail subject heading
4. Save your changes to the file.
5. Refresh the home.htm file in your browser. Verify that the text contact me in the
opening paragraph now appears as a hypertext link.
6. Click contact me and verify that your e-mail program displays a message with
ghayward@camshots.com as the recipient and CAMshots Message as the subject.
Trouble? If you are using a Web-based e-mail client such as Gmail or Hotmail,
the browser will not open your e-mail client. You can view online documentation
for your browser to determine whether it supports linking to Web-based e-mail
clients.
7. Close your message window without saving the message.
Search WWH ::




Custom Search