hgroup tag in html5 with example

  1. The HTML <hgroup> tag is used for defining the header of an HTML document or section. 
  2. More specifically, it is used to group a set of<h1>-<h6> elements when the heading has multiple levels, such as subheadings, alternative titles, or taglines.
  3. The <hgroup> tag is supported in Internet Explorer 9, Firefox, Opera, Chrome, and Safari. IE8 and earlier versions does not support hgroup element.

Example 1 :

    <head><title>mark tag in html5</title>
            <h1>This is h1 element.</h1>
            <h3>This is h3 element inside hgroup element.</h3> 

Demo :

In the above example, we have shown how to use hgroup element in a document.


Post a Comment