HTML and CSS Reference
In-Depth Information
so too could a Web document be structured in this way. The example here illustrates the
basic use of HTML5 sections:
<h1> Chapter 2 </h1>
<p> New HTML5 elements .</p>
<h2> HTML5's section Element </h2>
<p> These elements are useful to create outlines .</p>
<h3> Nest Away! </h3>
<p> Nest your sections but as you nest you might want to indent. </p>
<p> Ok that's enough of that. </p>
It may not be obvious but a section element may contain header and footer elements
of its own:
<h1> I am Section Heading </h1>
<h2> I am outside the section header I'm just a plain headline. </h2>
<p> Some more section content might go here. </p>
<p> Hi from the footer of this section. </p>
HTML5 uses headings and newly introduced elements like the section element for
outlining purposes. For example, the expanded example here shows a number of sections
with headers, footers, headlines, and content:
<!DOCTYPE html>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title> HTML5 expanded section example </title>
<h1> Welcome to the Future World of HTML5 </h1>
<h2> Don't be scared it isn't that hard! </h2>
Search WWH ::

Custom Search