HTML and CSS Reference
long answer is a little more complex. Consider this question: what does
it mean to say that a browser supports the <p> element?
It turns out that the first requirement is easy to satisfy—as long as you
follow simple tag-naming rules, you can put any tags in your HTML , and
all browsers will put the tags in the DOM with a default set of properties.
Where problems arise is with regard to the second requirement: having
a default presentation. Browsers have only recently started providing
any default presentation for the new elements in HTML5 ; for instance,
Firefox 3.6 doesn't, but Firefox 4.0 does. But this isn't much of a prob-
lem. As you know, we web authors define our content in HTML and
our presentation in CSS —and browsers work exactly the same way.
The default presentation for the supported elements is defined in CSS .
If you use Firefox, you can even find this file on your hard drive—it's
Using these new elements is a matter of taking on the responsibility
of providing some default CSS rules for them. In most cases you'll
want to write CSS for these elements anyway, so this doesn't seem
like too much effort. Let's see how it works with an example.
Here's a simple HTML5 document to experiment with:
<h1>Hello! HTML 5</h1>
<h2>An example page by Rob Crowther</h2>
<li><a href="#">Link 1</a></li>
<li><a href="#">Link 2</a></li>
<li><a href="#">Link 3</a></li>
<article>The first article.</article>
<article>The second article.</article>