{{ APIRef}}
The HTMLHeadingElement
interface represents the different heading elements. It inherits methods and properties from the {{domxref("HTMLElement")}} interface.
Properties
Inherits properties from its parent, {{domxref("HTMLElement")}}.
Name | Type | Description |
---|---|---|
align {{obsolete_inline}} |
{{domxref("DOMString")}} | Enumerated attribute indicating alignment of the heading with respect to the surrounding context. |
Methods
No specific method; inherits methods from its parent, {{domxref("HTMLElement")}}.
Specifications
Specification | Status | Comment |
---|---|---|
{{SpecName('HTML WHATWG', "sections.html#the-h1,-h2,-h3,-h4,-h5,-and-h6-elements", "HTMLHeadingElement")}} | {{Spec2('HTML WHATWG')}} | No change from {{SpecName("HTML5 W3C")}}. |
{{SpecName('HTML5 W3C', "sections.html#the-h1,-h2,-h3,-h4,-h5,-and-h6-elements", "HTMLHeadingElement")}} | {{Spec2('HTML5 W3C')}} | The align property is now obsolete. |
{{SpecName('DOM2 HTML', 'html.html#ID-43345119', 'HTMLHeadingElement')}} | {{Spec2('DOM2 HTML')}} | No change from {{SpecName("DOM1")}}. |
{{SpecName('DOM1', 'level-one-html.html#ID-43345119', 'HTMLHeadingElement')}} | {{Spec2('DOM1')}} | Initial definition. |
Browser compatibility
{{CompatibilityTable}}
Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari (WebKit) |
---|---|---|---|---|---|
Basic support | {{CompatVersionUnknown}} | {{CompatGeckoDesktop(1.0)}} | {{CompatVersionUnknown}} | {{CompatVersionUnknown}} | {{CompatVersionUnknown}} |
Feature | Android | Firefox Mobile (Gecko) | IE Phone | Opera Mobile | Safari Mobile |
---|---|---|---|---|---|
Basic support | {{CompatVersionUnknown}} | {{CompatGeckoMobile(1.0)}} | {{CompatVersionUnknown}} | {{CompatVersionUnknown}} | {{CompatVersionUnknown}} |
See also
- The HTML element implementing this interface: {{ HTMLElement("h1") }}, {{ HTMLElement("h2") }}, {{ HTMLElement("h3") }}, {{ HTMLElement("h4") }}, {{ HTMLElement("h5") }}, and {{ HTMLElement("h6") }}.