HTML and CSS Reference
In-Depth Information
2
CHAPTER
Introducing HTML5
The HTML5 specification not only embraces the past, by supporting traditional
HTML- and XHTML-style syntax, but also adds a wide range of new features.
Although HTML5 moves forward from HTML 4, it also is somewhat of a retreat and
an admission that trying to get every Web developer on the Internet to write their markup
properly is a futile effort, particularly because few Web developers are actually formally
trained in the technology. HTML5 tries to bring order to chaos by codifying common
practices, embracing what is already implemented in browsers, and documenting how
these user agents (browsers or other programs that consume Web pages) should deal with
our imperfect markup.
HTML5's goals are grand. The specification is sprawling and often misunderstood.
Given the confusion, the goals of this chapter are not only to summarize what is new about
HTML5 and provide a roadmap to the element reference that follows, but to also expose
some of the myths and misconceptions about this exciting new approach to markup.
N OTE Perhaps just to be new, HTML5 omits the space found commonly between (X)HTML and its
version number, as in HTML 4 or XHTML 1. We follow this style generally in the topic, but note
even the specification has not been stringent on this point.
Hello HTML5
The syntax of HTML5 should be mostly familiar. As shown in the previous chapter, a simple
HTML5 document looks like this:
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title> Hello HTML5 World </title>
</head>
<body>
<h1> Hello HTML5 </h1>
<p> Welcome to the future of markup !</p>
</body>
</html>
55
Search WWH ::




Custom Search