hgroup

Table of contents

  1. 1. Summary
    1. 1.1. Usage context
    2. 1.2. Attributes
    3. 1.3. DOM Interface
    4. 1.4. Examples
    5. 1.5. Compatibility
    6. 1.6. See also
Table of contents
  1. 1. Summary
    1. 1.1. Usage context
    2. 1.2. Attributes
    3. 1.3. DOM Interface
    4. 1.4. Examples
    5. 1.5. Compatibility
    6. 1.6. See also

Introduced in HTML 5

Summary

The HTML Headings Group Element (<hgroup>) represents the heading of a section. It defines a single title that participates in the outline of the document as the heading of the implicit or explicit section that it belongs too.

Its text for the outline algorithm is the text of the first HTML Heading Element of highest rank (i.e., the first <h1> , <h2> , <h3> , <h4> , <h5> or <h6> with the smallest number among its descendants) and the rank is the rank of this very same HTML Heading Element.

Therefore this element groups several headings, contributing only the main one to the outline of the document. It allows associating secondary titles, like subheadings, alternative titles, or even taglines, with the main heading, without polluting the outline of the document.

Usage context

Permitted content Zero or more HTML Heading Elements (<h1> , <h2> , <h3> , <h4> , <h5> , <h6> )
Tag omission None, both the start tag and the end tag are mandatory
Permitted parent elements

Any element that accepts flow content.

Normative document HTML5, section 4.4.7

Attributes

This element has no other attributes than the global attributes, common to all elements.

DOM Interface

This element implements the HTMLElement interface.

Examples

<hgroup>
  <h1>Main title</h1>
  <h2>Secondary title</h2>
</hgroup>

Compatibility

  • Desktop
  • Mobile

Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari
Basic support 5 4.0 (2.0) 9.0 11.10 4.1
Feature Android Firefox Mobile (Gecko) IE Mobile Opera Mobile Safari Mobile
Basic support 2.2 4.0 (2.0) 9.0 11.0 5.0 (iOS 4.2)

See also

Tags (4)

Edit tags

Attachments (0)

 

Attach file