Appendix: HTML5 Elements and Attributes

These tables provide a reference to some of the most commonly used HTML5 elements, the category of content they belong to as well as their attributes. Although there are new elements in HTML5, some elements from HTML 4.0.1 (such as b and i) have been revised.

This table is not a complete list, for complete references please visit http://www.w3.org/TR/html5/index.html.

For an overview of HTML5 syntax, be sure to read Lesson 2 “Using HTML5 markup”.

8315.jpg In the Attributes column, “globals” refers to common attributes that may be specified on all HTML elements. These attributes are accesskey, class, contenteditable, contextmenu, dir, draggable, dropzone, hidden, id, lang, spellcheck, style, tabindex, title, and are described in further detail below.

Table 1 List of current HTML5 elements

Element

Description

Attributes

a

Hyperlink

globals; href; target; rel; media; hreflang; type

abbr

Abbreviation

globals

address

Contact information for a page or section

globals

area

Hyperlink or dead area on an image map

globals; alt; coords; shape; href; target; rel; media; hreflang; type

article

Self-contained syndicatable or reusable composition

globals

aside

Sidebar for tangentially related content

globals

audio

Audio player

globals; src; preload; autoplay; mediagroup; loop; controls

Get HTML5 Digital Classroom now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.