Programming

Programming intro
Java

Markup

First webpage guide
HTML
XHTML

Style & Layout

CSS

Browser scripting

Javascript
VBScript
AJAX

Server scripting

PHP
ASP

Making money online

Make money online

HTML head section

It is said that sometimes what you don't see is very important, and this holds true for HTML documents. The information placed in the head section of an HTML document is not seen on a webpage but is very important for the page itself.

The head section of an HTML document begins with <head> and ends with </head>.

Tags placed inside the head section of an HTML document:

Another important tag that describes a webpage in some way is the <!DOCTYPE> tag. This tag specifies what kind of document an HTML document will be.

For HTML documents that use deprecated features such as the <font> tag use the transitional document type:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

For HTML documents that contain frames, use the frameset document type:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN"
"http://www.w3.org/TR/html4/frameset.dtd">

For HTML documents that use CSS and no deprecated features such as the <font> tag use the strict document type:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">

For XHTML documents that use deprecated features such as the <font> tag use the transitional document type:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

For XHTML documents that contain frames, use the frameset document type:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">

For XHTML documents that use CSS and no deprecated features such as the <font> tag use the strict document type:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

NOTE: The <!DOCTYPE> tag should be the first line of code in an HTML document!

Reference
HTML/XHTML
CSS
Javascript
AJAX

Practice

Online code editor
Step-by-step tutorials
Practical examples
Practical exercises

Reference

Terms glossary

Rate this site

Rate this site
Visitor comments