Lecture Notes 4a:
Web Page Metadata

CSE 190 M (Web Programming), Spring 2007

University of Washington

Reading: Sebesta Ch. 2 sections 2.4.7, 2.4.9

Valid XHTML 1.0 Strict Valid CSS!

Web page metadata: <meta>

information about your page (for a browser, search engine, etc.)

<meta name="description" 
 content="Authors' web site for Building Java Programs." />
<meta name="keywords" content="java, textbook" />
<meta http-equiv="Content-Type"
 content="text/html; charset=iso-8859-1" />

meta element to describe the page

<head>
<meta name="author"
 content="web page's author" />
<meta name="revised"
 content="web page version and/or last modification date" />
<meta name="generator"
 content="the software used to create the page" />
</head>

meta element to aid search engines

<head>
<meta name="description"
 content="how you want search engines to display your page" />
<meta name="keywords"
 content="words to associate with your page (comma-separated)" />
</head>

meta element to aid browser / web server

<meta http-equiv="refresh"
 content="how often to refresh the page (seconds)" />
</head>
<meta http-equiv="Content-Type" 
 content="what type of document this is 
 (may include internationalization information such as character encoding)" />

Favorites icon ("favicon")

<link rel="shortcut icon" type="MIME type" href="filename" />
<link rel="shortcut icon" type="image/gif" href="cse.gif" />

favicon favicon

Internet media ("MIME") types

classifications of data that travel over the internet

HTML Character Entities

a way of representing any Unicode character within a web page

character(s)entity
< >&lt; &gt;
é è ñ&eacute; &egrave; &ntilde;
™ ©&trade; &copy;
π δ Δ&pi; &delta; &Delta;
И&#1048;
" &&quot; &amp;

HTML-encoding text

<p><a href=
"http://www.google.com/search?q=marty+stepp&ie=utf-8&aq=t">
Search Google for Marty</a></p>
&lt;p&gt;&lt;a href=
&quot;http://www.google.com/search?q=marty+stepp&amp;ie=utf-8&amp;aq=t&quot;&gt;
Search Google for Marty&lt;/a&gt;&lt;/p&gt;