http://fishcaro.crosswinds.net/day_19_more_header_tags.htm
(If you have Internet Explorer 5.0 or higher, you should see a really neat rainbow effect on the heading for this lesson!)
Although the <TITLE> tag is the most common tag to include in the
header (i.e., inside the
<HEAD> </HEAD> container), there are two other tags that you should know about before tackling any big web project: the
<BASE> and <META> tags.
INDEX CARD #19:
THE <BASE> TAG (19a)<BASE> tag used for? The <BASE> tag is used to give the full URL for the
current document. It's optional: if you use it, it goes inside the
<HEAD> </HEAD> container.
For example, the tag for the current document would look something like this:
<BASE HREF="http://fishcaro.crosswinds.net/day_19_more_header_tags.htm">
day_19_more_header_tags.htm ") is stripped away,
and the remaining path is used as the base to get the absolute
URL.
For example, if the tag <A HREF="graphics/pic_1.gif"> is
encountered, the browser will actually request the absolute URL:
http://fishcaro.crosswinds.net/graphics/pic_1.gif BASE tag, then the
URL used to access the document forms the base for the absolute URL (which is
usually what you want). One use of the BASE tag is for large, multi-page documents (like this web course). If
someone were to copy a single page of this course (without a BASE tag) to their hard drive
and load it into a browser, none of the relative URLs would work. With the base tag, however, all the relative URLs
are "turned into" the proper absolute URLs.
(The BASE tag is also useful when working with frames, and
will be discussed in a future lesson.)
|
THE <META> TAG (19b)<META> tag used for? The primary use
for the <META> tag is to include information about
a document, such as its creation date, author, copyright information,
and keywords. This information is used by servers, web browsers, and
search engines, but is invisible to the reader. The <META>
tag must go inside the <HEAD> </HEAD> container.
The NAME attribute specifies the type of meta
information you're giving (like "author"); the CONTENT attribute then gives the actual value, like this:
<META NAME="author" CONTENT="Carol J.V. Fisher"> NAME values are:
|
Printable version of Index Card 19a
Printable version of Index Card 19b
WORKSHEET #19:
ASSIGNMENT #19:
HTTP-EQUIV
attribute for the META
tag is interesting; we'll talk more
about it later on.
<BASE>
tag in your homepage file. You may
have to check with your local computer guru to get the proper base.
META
information I've given.
META
information in the header of your homepage file:
<META NAME="author" CONTENT="your name">
<META NAME="description" CONTENT="a brief description of your site">
<META NAME="keywords" CONTENT="keywords for your site">
<META NAME="generator" CONTENT="name and version of the creation tool">
META
tag: