Use header Tag in HTML5

Leave a Comment

Use the structural <header></header> element to create a document or section header. It can also contain <h1> to <h6>; although, as you will see later in this chapter, they are better served by the
<hgroup></hgroup> element. You can also use it to help place logos and a section’s table of contents.

The <header></header> element is an easy way to create introductions to both the document and to
sections.

Notice that in this example, the <hr> element is used to draw the horizontal line. This is not a requirement
of any kind.
<header>
<span style="color:red;font-style:italic;">
Baking Cheesecakes</span>
<hr>
</header>
<aside style="font-size:larger;font-style:italic;color:blue;float:right;width:120px;">
To create a water bath, use a pan that will allow you to fill it with boiling water that
goes halfway up the spring form pan in which the cake is placed.
</aside>
<p>
When baking a cheesecake, it is important not to over bake it. You only want to bake it
until the middle has a slight wiggle, not until it is rock solid.
</p><p>It is important that you use a water bath, discussed at the right, to ensure even baking of your cheesecake.</p>

You can use the <header></header> structural element as an introduction to most of the other structural elements in the document.

You cannot use the <header></header> element within the <footer>, <address>, or other <header>
elements. If you do, the result will be improper rendering.

0 comments:

Post a Comment