Appendix I

Changes between HTML4 and HTML5

This document outlines the major element differences between HTML4 and HTML5. For a full view of all the changes, see the W3C’s document “HTML5 Differences from HTML4” at www.w3.org/TR/html5-diff/.

New Elements

The following list represents all the new elements introduced in HTML5. For descriptions of these elements, see Appendix B, “HTML Element Reference”:

  • section
  • article
  • aside
  • hgroup
  • header
  • footer
  • nav
  • figure
  • figcaption
  • video
  • audio
  • track
  • embed
  • mark
  • progress
  • meter
  • time
  • ruby
  • rt
  • rp
  • bdi
  • wbr
  • canvas
  • command
  • cetails
  • catalist
  • keygen
  • output

New <input> Element Types

The input element’s type attribute now has the following new values. For descriptions of these elements, see Appendix B, “HTML Element Reference”:

  • tel
  • search
  • url
  • email
  • datetime
  • date
  • month
  • week
  • time
  • datetime-local
  • number
  • range
  • color

New Attributes

Many new attributes have been added to existing elements. These new attributes either are existing attributes added to new elements or are completely new attributes. These are also covered in depth alongside their elements in Appendix B, “HTML Element Reference”:

ElementAttributes
<a>media
<area>hreflang, media, rel, type
<base>target
<button>autofocus,form, formaction, formenctype, formmethod, formnovalidate, formtarget
<fieldset>disabled, form, name
<form>novalidate
<html>manifest
<iframe>sandbox, seamless, srcdoc
<img>crossorigin
<input>autocomplete, autofocus, dirname, form,formaction, formenctype, formmethod, ...

Get Beginning HTML and CSS now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.