Wednesday, September 22, 2010

HTML 5 Structure


HTML 5 came out with a whole new set of elements to make structuring a web page much easier. When marking up a page in HTML 4 most of the structure was contained within div elements.






Current versions of HTML 4 do not give us the ability to describe these parts more accurately. HTML 5 addresses this by giving us new elements that correspond with each of the basic layouts of a web page.





The markup would look like this:



<html>
<header>
<title>...</title>
</header>
<body>
<header>...</header>
<nav>...</nav>
<aside>...</aside>
<article>
<section>...</section>
</article>
<footer>...</footer>
</body>
</html>


For more information on the differences between HTML 4 and HTML 5 take a look at W3C

No comments:

Post a Comment