The <header> Element

In HTML4, we would define a header like this:

<div id=“header”>
 

In HTML5, a simple <header> tag is used, instead.

The <header> element is appropriate for use inside the body tag.

<!DOCTYPE html>
<html>
   <head></head>
   <body>
      <header>
        <h1> Most important heading </h1>
        <h3> Less important heading </h3>
      </header>
   </body>
</html>
 

Holla Tech - Learn HTML5

This is box title
Note that the <header> is completely different from the <head> tag.

The <footer> Element

The footer element is also widely used. Generally we refer to a section located at the very bottom of the web page as the footer.

<footer></footer>
 

This is box title
The following information is usually provided between these tags: – Contact Information – Privacy Policy – Social Media Icons – Terms of Service – Copyright Information – Sitemap and Related Documents

The <nav> Element

This tag represents a section of a page that links to other pages or to certain sections within the page. This would be a section with navigation links.

Here is an example of a major block of navigation links:

<nav>
   <ul>
      <li><a href="#">Home</a></li>
      <li><a href="#">Services</a></li>
      <li><a href="#">About us</a></li>
   </ul>
</nav>
 

Holla Tech - Learn HTML5

This is box title
Not all of the links in a document should be inside a <nav> element. The <nav> element is intended only for major blocks of navigation links. Typically, the <footer> element often has a list of links that don’t need to be in a <nav> element.


BACK NEXT

HTML MAIN COURSE PAGE

 

CONTACT HOLLA TECH LEARN SUPPORT