April 2013
Intermediate to advanced
264 pages
7h 44m
English
One of the major new features in HTML5 is a range of new semantic elements, extending the suite far beyond its roots in marking up scientific documents with headings, lists, and paragraphs. Most of the new elements are aimed at giving a page better structure and developers more options for marking up areas of content than just using a div with an associated id or classes.
Here’s one example. In the past, developers might have used this:
<div class="article">…</div>
In HTML5, they have the option of using this:
<article>…</article>
The W3C’s HTML5 spec lists ten structural elements. Of these, three already existed in HTML4: body, h1–h6 (if we cheat a little and count them as a single entity), and address. Of the seven new ...
Read now
Unlock full access