HTML and CSS Reference
In-Depth Information
browser send this information or to use a special program called an FTP client , which
can encrypt or hide this information during transmission.
Linking to a Local File
HTML is a very useful language for creating collections of linked documents. Many soft-
ware developers have chosen to distribute their online help in the form of HTML fi les.
The Web sites for these help fi les then exist locally on a user's computer or network. If
a Web site needs to reference local fi les (as opposed to fi les on the Internet or another
wide area network), the URLs need to refl ect this fact. The URL for a local fi le has the
general form
fi le:// server / path / fi lename
where server is the name of the local network server, path is the path on that server
to the fi le, and fi lename is the name of the fi le. If you're accessing a fi le from your own
computer, the server name can be omitted and replaced by an extra slash (/). Thus, a fi le
from the documents / articles folder might have the following URL:
fi le:///documents/articles/tips.htm
If the fi le is on a different disk within your computer, the hard drive letter would be
included in the URL as follows:
fi le://D:/documents/articles/tips.htm
Unlike the other URLs you've examined, the fi le scheme in this URL does not imply any
particular communication protocol; instead, browsers retrieve the document using what-
ever method is the local standard for the type of fi le specifi ed in the URL.
Linking to an E-Mail Address
Many Web sites use e-mail to allow users to communicate with a site's owner, sales
representative, or technical support staff. You can turn an e-mail address into a hyper-
text link; when a user clicks the link, the user's e-mail program opens and automatically
inserts the e-mail address into the To fi eld of a new outgoing message. The URL for an
e-mail address follows the form
mailto: address
where address is the e-mail address. To create a hypertext link to the e-mail address
ghayward@camshots.com , yo u could use the following URL:
mailto:ghayward@camshots.com
The mailto protocol also allows you to add information to the e-mail, including the
subject line and the text of the message body. To add this information to the link, you use
theĀ form
To link to more than
one e-mail address,
add the addresses to
the mailto link in a
comma-separated list.
mailto: address ? header1 = value1 & header2 = value2 &...
where header1 , header2 , etc. are different e-mail headers and value1 , value2 , and so
on are the values of the headers. Thus, to create a link containing the e-mail message
TO: ghayward@camshots.com
SUBJECT: Test
BODY: This is a test message
you would use the following URL:
mailto:ghayward@camshots.com?subject=Test&Body=This%20is%20a%
20test%20message
Search WWH ::




Custom Search