IN the new specification, each defined element has a content model which is a description of it's expected contents. An HTML element must have content that match the requirements described in it's model.
- The following seven categories are used in the new specification:
- Metadata
- Embedded
- Interactive
- Phrasing
- Flow
- Sectioning
- Heading (hgroup, h1 - h6)
Metadata is content that sets up the presentation or behavior of the rest of the content. Elements can include: base, command, link ,meta, noscript, script style, and title. Metadata is typically found in the head of the document.
In HTML 5, Doctype declarations have been simplified to one.The Doctype is: <!DOCTYPE html>. The document type must be declared on line one of the HTML document.
Embedded content imports other resources into the document. Elements include: audio, canvas, embed, iframe, img, math, object, svg, and video.
Interactive content is specifically intended for user interaction. Elements include: a, audio, button details, embed, iframe, img, input, keygen, label, object, select, textarea, and video.
Phrasing is the text of the document as well as the elements used to mark up the text within paragraph level structures. In many ways it is the same as inline content from the HTML4 specifications. Elements can include: a, abbr, area, audio, button, canvas, cite, code, command, datalist, del, dfn, div, dl, em, embed, fieldset, figure, footer, form, h1 - h6, header, hgroup, hr, i, iframe, img, input, ins, kbd, keygen, label, link, map, mark, math, menu, meta, meter, nav, noscript, object, ol, output, p, pre, progress, q, ruby samp, script, section, select, small, span, strong, style, sub, sup, svg, table, textarea, ul, time, var, video, wbr.
Flow elements are those that would be included in the normal flow of the document and contain the majority of elements included in HTML5. Being identified as flow content has no bearing on how the content will be displayed in the user agent. Elements can include: a, abbr, area, article, aside, audio, b, bdo, blockquote, br, details, button, canvas, cite, code, command, datalist, del, dfn, embed, I, iframe, img, input, ins, kbd, keygen, label, link, map, mark, math, meta, meter, noscript, object, output, progress, q, ruby samp, script, select, small, span, strong, sub, sup, svg, textarea, var, video, wbr.
Sectioning defines the scope of the headers and footers. Elements include: article, aside nav, and section.
The heading model defines the header of a section, which can either be explicitly marked up with sectioning elements or implied by the heading content itself. Elements include: h1 - h6, hgroup.