1 Introduction
2 Basic Templates
3 The HTML and XHTML Syntax
3.1 Syntactic Overview
3.2 The Syntax
3.2.1 DOCTYPE Declaration
3.2.1.1 Obsolete But Permitted DOCTYPEs
3.2.1.2 HTML and XHTML Comparison
3.2.1.3 Historical Notes
3.2.2 Elements
3.2.2.1 Tags
3.2.2.2 Void Elements
3.2.2.3 Raw Text Elements
3.2.2.4 RCDATA Elements
3.2.2.5 Foreign Elements
3.2.2.6 Normal Elements
3.2.2.7 Element Type Comparision
3.2.2.8 HTML and XHTML Comparison
3.2.3 Attributes
3.2.3.1 Empty Attribute Syntax
3.2.3.2 Unquoted Attribute Value Syntax
3.2.3.3 Double-Quoted Attribute Value Syntax
3.2.3.4 Single-Quoted Attribute Value Syntax
3.2.3.5 HTML and XHTML Comparison
3.2.4 Comments
3.2.5 Text
3.2.6 CDATA Sections
3.2.7 Character References
3.3 Understanding MIME Types
3.4 Character Encoding
3.5 Choosing HTML or XHTML
3.6 Polyglot Documents
4 The HTML Vocabulary and APIs
4.1 Categories
4.1.1 Metadata Content
4.1.2 Flow content
4.1.3 Sectioning root
4.1.4 Sectioning content
4.1.5 Heading content
4.1.6 Phrasing content
4.1.7 Embedded content
4.1.8 Interactive content
4.1.9 Transparent Content Models
4.2 Global Attributes
4.3 The Elements
4.3.1 The Root Element
4.3.1.1 The html
element
Attributes
DOM Interface
4.3.2 Document Metadata
4.3.2.1 The head
element
Attributes
DOM Interface
4.3.2.2 The title
element
Attributes
DOM Interface
4.3.2.3 The base
element
Attributes
DOM Interface
4.3.2.4 The link
element
Attributes
DOM Interface
4.3.2.5 The meta
element
Attributes
DOM Interface
4.3.2.6 The style
element
Attributes
DOM Interface
4.3.3 Scripting
4.3.3.1 The script
element
Attributes
DOM Interface
4.3.3.2 The noscript
element
Attributes
DOM Interface
4.3.4 Sections
4.3.4.1 The body
element
Attributes
DOM Interface
4.3.4.2 The section
element
Attributes
DOM Interface
4.3.4.3 The nav
element
Attributes
DOM Interface
4.3.4.4 The article
element
Attributes
DOM Interface
4.3.4.5 The aside
element
Attributes
DOM Interface
4.3.4.6 The h1
, h2
,
Attributes
DOM Interface
4.3.4.7 The header
element
Attributes
DOM Interface
4.3.4.8 The footer
element
Attributes
DOM Interface
4.3.4.9 The address
element
Attributes
DOM Interface
4.3.4.10 Headings and Sections
4.3.5 Grouping Content
4.3.5.1 The p
element
Attributes
DOM Interface
4.3.5.2 The hr
element
Attributes
DOM Interface
4.3.5.3 The br
element
Attributes
DOM Interface
4.3.5.4 The pre
element
Attributes
DOM Interface
4.3.5.5 The dialog
element
Attributes
DOM Interface
4.3.5.6 The blockquote
element
Attributes
DOM Interface
4.3.5.7 The ol
element
Attributes
DOM Interface
4.3.5.8 The ul
element
Attributes
DOM Interface
4.3.5.9 The li
element
Attributes
DOM Interface
4.3.5.10 The dl
element
Attributes
DOM Interface
4.3.5.11 The dt
element
Attributes
DOM Interface
4.3.5.12 The dd
element
Attributes
DOM Interface
4.3.6 Text-Level Semantics
4.3.6.1 The a
element
Attributes
DOM Interface
4.3.6.2 The q
element
Attributes
DOM Interface
4.3.6.3 The cite
element
Attributes
DOM Interface
4.3.6.4 The em
element
Attributes
DOM Interface
4.3.6.5 The strong
element
Attributes
DOM Interface
4.3.6.6 The small
element
Attributes
DOM Interface
4.3.6.7 The mark
element
Attributes
DOM Interface
4.3.6.8 The dfn
element
Attributes
DOM Interface
4.3.6.9 The abbr
element
Attributes
DOM Interface
4.3.6.10 The time
element
Attributes
DOM Interface
4.3.6.11 The progress
element
Attributes
DOM Interface
4.3.6.12 The meter
element
Attributes
DOM Interface
4.3.6.13 The code
element
Attributes
DOM Interface
4.3.6.14 The var
element
Attributes
DOM Interface
4.3.6.15 The samp
element
Attributes
DOM Interface
4.3.6.16 The kbd
element
Attributes
DOM Interface
4.3.6.17 The sub
and sup
elements
Attributes
DOM Interface
4.3.6.18 The span
element
Attributes
DOM Interface
4.3.6.19 The i
element
Attributes
DOM Interface
4.3.6.20 The b
element
Attributes
DOM Interface
4.3.6.21 The bdo
element
Attributes
DOM Interface
4.3.6.22 The ruby
element
Attributes
DOM Interface
4.3.6.23 The rt
element
Attributes
DOM Interface
4.3.6.24 The rp
element
Attributes
DOM Interface
4.3.7 Edits
4.3.7.1 The ins
element
Attributes
DOM Interface
4.3.7.2 The del
element
Attributes
DOM Interface
4.3.8 Embedded Content
4.3.8.1 The figure
element
Attributes
DOM Interface
4.3.8.2 The img
element
Attributes
DOM Interface
4.3.8.3 The iframe
element
Attributes
DOM Interface
4.3.8.4 The embed
element
Attributes
DOM Interface
4.3.8.5 The object
element
Attributes
DOM Interface
4.3.8.6 The param
element
Attributes
DOM Interface
4.3.8.7 The video
element
Attributes
DOM Interface
4.3.8.8 The audio
element
Attributes
DOM Interface
4.3.8.9 The source
element
Attributes
DOM Interface
4.3.8.10 The canvas
element
Attributes
DOM Interface
4.3.8.11 The map
element
Attributes
DOM Interface
4.3.8.12 The area
element
Attributes
DOM Interface
4.3.9 Tabular Data
4.3.9.1 The table
element
Attributes
DOM Interface
4.3.9.2 The caption
element
Attributes
DOM Interface
4.3.9.3 The colgroup
element
Attributes
DOM Interface
4.3.9.4 The col
element
Attributes
DOM Interface
4.3.9.5 The tbody
element
Attributes
DOM Interface
4.3.9.6 The thead
element
Attributes
DOM Interface
4.3.9.7 The tfoot
element
Attributes
DOM Interface
4.3.9.8 The tr
element
Attributes
DOM Interface
4.3.9.9 The td
element
Attributes
DOM Interface
4.3.9.10 The th
element
Attributes
DOM Interface
4.3.10 Forms
4.3.10.1 The form
element
Attributes
DOM Interface
4.3.10.2 The fieldset
element
Attributes
DOM Interface
4.3.10.3 The label
element
Attributes
DOM Interface
4.3.10.4 The input
element
Attributes
DOM Interface
4.3.10.5 The button
element
Attributes
DOM Interface
4.3.10.6 The select
element
Attributes
DOM Interface
4.3.10.7 The datalist
element
Attributes
DOM Interface
4.3.10.8 The optgroup
element
Attributes
DOM Interface
4.3.10.9 The option
element
Attributes
DOM Interface
4.3.10.10 The textarea
element
Attributes
DOM Interface
4.3.10.11 The output
element
Attributes
DOM Interface
4.3.11 Interactive Elements
4.3.11.1 The details
element
Attributes
DOM Interface
4.3.11.2 The command
element
Attributes
DOM Interface
4.3.11.3 The bb
element
Attributes
DOM Interface
4.3.11.4 The menu
element
Attributes
DOM Interface
4.3.12 Miscellaneous Elements
4.3.12.1 The legend
element
Attributes
DOM Interface
4.3.12.2 The div
element
Attributes
DOM Interface
4.4 Microdata
5 Index of Elements
5.1 Conforming Elements
5.2 Obsolete Elements
5.3 Comparison of HTML 4.01 and HTML5 Elements
6 How to Read This Guide
6.1 Conventions
6.1.1 Notes, Tips and Warnings
6.1.2 Example Markup
6.1.2.1 Attributes
6.1.2.2 Void Elements
6.1.2.3 Namespaces
header
elementfooter
elementaddress
elementp
elementhr
elementbr
elementpre
elementdialog
elementblockquote
elementol
elementul
elementli
elementdl
elementdt
elementdd
elementa
elementq
elementcite
elementem
elementstrong
elementsmall
elementmark
elementdfn
elementabbr
elementtime
elementprogress
elementmeter
elementcode
elementvar
elementsamp
elementkbd
elementsub
and sup
elementsspan
elementi
elementb
elementbdo
elementruby
elementrt
elementrp
elementins
elementdel
elementfigure
elementimg
elementiframe
elementembed
elementobject
elementparam
elementvideo
elementaudio
elementsource
elementcanvas
elementmap
elementarea
elementtable
elementcaption
elementcolgroup
elementcol
elementtbody
elementthead
elementtfoot
elementtr
elementtd
elementth
elementform
elementfieldset
elementlabel
elementinput
elementbutton
elementselect
elementdatalist
elementoptgroup
elementoption
elementtextarea
elementoutput
elementdetails
elementcommand
elementbb
elementmenu
elementlegend
elementdiv
element