Skip to main content

Bulletproof HTML: 37 Steps to Perfect Markup [HTML & XHTML Tu...

Popularity Report

Total Popularity Score: 0

Loading...
Loading...
Loading...
Loading...
Loading...
Loading...

Rank

Public Comment

on 2006-11-28 by mamouri

good html practices and advanced lessons

Public Sticky notes

6. What is a DTD?

A DTD, or document type definition, specifies the element types and attributes that we can use in our web page. It also defines the rules of how we can use these elements together -- it's the specification for our markup language. The DTD can also declare the character entities we can use; more about those later.

A validator will test a web page for compliance with the DTD specified in the DOCTYPE declaration either explicitly, via the system identifier, or implicitly, using the public identifier. Browsers use non-validating parsers and do not actually read the DTD. They have built-in knowledge about the various element types, and usually a hard-coded list of character entities as well.

For HTML 4.01, which is the latest and greatest version, there are three different DTDs: Strict, Transitional and Frameset.

Highlighted by scrupeda

If we are creating a new web page, the W3C recommends that we use HTML 4.01 Strict.

Highlighted by scrupeda

7. What is the difference between Strict, Transitional and Frameset DTDs?

Highlighted by scrupeda

8. Which DOCTYPE should I use?

Highlighted by scrupeda

12. What does character encoding (charset) mean?

Highlighted by scrupeda