HTML and CSS Reference
In-Depth Information
background - color : #FCC;
}
</ style >
< meta http - equiv = ”Content-Type” content = ”text/html; charset=UTF-8” >
< title > Home Base </ title ></ head >
< body >
< h1 > This Is the Home Base </ h1 >
< a href = ”FirstBase.html” > First Base </ a >
</ body ></ html >
<! DOCTYPE HTML >
< html >< head >
< base href = ”http://www.sandlight.com/html5/smashing/ “ >
< style type = ”text/css” >
body {
background - color : #FC0;
}
</ style >
< meta http - equiv = ”Content-Type” content = ”text/html; charset=UTF-8” >
< title > First Base </ title >
</ head >
< body >
< h1 > This Is First Base </ h1 >
< a href = ”Base.html” > Home Base </ a >
</ body >
</ html >
87
What is happening here? h e <base> tag is telling your browser how to resolve any refer-
ences to other documents in your HTML — such as the <a href=”Base.html”> anchor
tag. Your browser will know to look for the Base.html document in the location specii ed
in the <base> tag; namely, http://www.sandlight.com/html5/smashing/ .
ADDING CHARACTER TO YOUR SITE WITH METADATA
To this point, we've used the <meta> tag to establish that your site uses the UTF-8 character
set, but the meta element can do much more. h ink of the meta element as the one that
performs multitasks. One of the most important attributes of the meta element is the name
and contents pair. With the name attribute set to keywords , you can specify the
contents on your site. In this way, the search engines can i nd your site when people are
trying to i nd your products or services — or just the topics you'd like to include on your Web
pages. For example, suppose your site has links to blogs and other sites on topics about dog
kennels. Your meta tag would look something like this:
< meta name = ”keywords” content = ”kennels, dog fences, pet containment” >
Each of the content values must be separated by a comma. h ese tokens can be directly
related to your content or what someone might look for. Content meta tags are easy to set and
you can help users i nd their way to your site.
 
Search WWH ::




Custom Search