274 Appendix A: HTML5 Quick Reference Element Description Content Model Attributes audio* Provides for the playing of an audio stream source src, controls, loop,autoplay, preload source
Trang 1274 Appendix A: HTML5 Quick Reference
Element Description Content Model Attributes
audio* Provides for the playing
of an audio stream source src, controls, loop,autoplay, preload source* Provides the source
information for a media element
empty src, type, media
canvas* Creates a bitmapped
rectangle that scripts can use for interactive manipulation of images and other media objects
transparent width, height
map Defines an image map area name
area Provides a hyperlink
corresponding to an area of an image map
empty href, alt, coords,
shape, target
details* Provides for additional
information that can
be exposed by the user agent in response to an event
summary, flow open
summary* Contains a summary,
caption, or legend for its
parent’s details element
phrasing
command* Creates a command
that the user can invoke empty type, icon, label,disabled, checked,
radiogroup menu* Creates a container for
a group of command
elements
li, flow type, label
Embedded Elements (continued)
Trang 2Table Elements
table Creates a
two-dimensional data
structure with rows and
columns
caption, colgroup
tr, thead, tbody, tfoot
cellspacing, cellpadding, border, width
tr Contains a row of table
cell elements th, td
th Represents a table cell
containing heading
content
phrasing width, height,
colspan, rowspan
td Represents a table cell
containing data content flow width, height,colspan, rowspan
caption Represents the caption or
title of its parent table flow
colgroup Creates a group of one or
more table columns col span
col Represents one or more
columns in a colgroup
element
tbody Represents a continuous
group of table rows
containing the body of
data in a table
tr
thead Represents a continuous
group of table rows
appearing before the
table’s body element
tr (th)
tfoot Represents a continuous
group of table rows
appearing after the table’s
body element
tr
Trang 3276 Appendix A: HTML5 Quick Reference
Form and Control Elements
Element Description Content Model Attributes
form Creates an area of the
page containing fields for user input, grouping those fields for processing
flow action, method,
enctype
fieldset Marks a section of a form
with an optional caption flow, legend form, disabled legend Represents a caption for
its containing fieldset
element
phrasing
label Represents a label for a
user input element or
control
phrasing form, for
input Creates a user input field
in a form element empty type, value,disabled, size,
required, hidden
list button Creates a clickable button phrasing type, value,
disabled select Creates either a drop
menu for a single option choice or a scrolling, multiple-choice menu
option multiple, size,
disabled
option Provides one choice of its
parent select element text label, value,disabled, selected
optgroup Groups option elements
with a common label option textarea Provides a multiline text
input field text rows, cols,required,
disabled, readonly datalist* Provides for setting
defaults for other input
elements
option
Trang 4Element Description Content Model Attributes
keygen* Marks an RSA encryption
key pair empty keytype,challenge,
disabled output* Marks the output of a
calculation in a form phrasing for, form, name
progress* Creates a widget that
displays the progress of a
task or process
phrasing value, max, form
meter* Creates a widget that
displays a value within a
known range
phrasing value, min,
max, low, high, optimum
Legacy Elements
big Indicates text that should be
rendered bigger than normal text phrasing
font Provides typographic styles flow face, size,
color blink Animates content, making it
appear and disappear phrasing
center Centers the content within the
containing element flow
frameset Groups a set of window frames,
each containing a separate
document
frame
frame Defines a document window that
is part of a browser frameset empty src, rows,cols
noframes Provides an alternative
document definition for user
agents that do not recognize
framesets
body content
continues
Trang 5278 Appendix A: HTML5 Quick Reference
applet Provides a container for the
execution of a Java applet flow code,codebase,
width, height dir Marks a directory listing li
strike Marks text that has been deleted text, phrasing
Legacy Elements (continued)
Trang 6The tables in this appendix summarize the CSS properties that can be
used to style HTML elements For each CSS property, the possible
values it can be assigned, the default or initial values given to
appli-cable elements, and whether the property’s value is inherited by child elements
are shown The tables are separated to indicate groups of complementary
properties
A default value of “ua-dependent” indicates that the value depends on the
user agent or browser
An asterisk (*) next to the property’s name indicates that it is a new CSS3
property and may not be supported on all browsers
Explanation of Values
Value Type Description
<angle> A positive or negative number between 0 and 360,
immediately followed by deg or rad
<color> A color name or #xxx or #xxxxxx or rgb(n, n, n), where x is
a hexadecimal digit (0 to 9, a, b, c, d, e, f) and n is an integer between 0 and 255 or a percentage
<integer> A number, without a decimal fraction, including 0, possibly
negative
continues
Trang 7280 Appendix B: CSS Properties
Value Type Description
<length> A percentage or a number followed by one of px, em, en, pt,
in, mm, cm
<name> An alphanumeric string representing a known object
<number> A real number, possibly negative, with or without a decimal
fraction
<percentage> A number between 0 and 100 followed immediately by the
percent sign (%)
<position> A pair of numbers indicating x- and y-coordinates
<rational> A number between 0 and 1
<rectangle> A pair of positions indicating the upper-left and lower-right
corners of a rectangle
<string> A character string, possibly empty
<time> A number immediately followed by s (seconds) or ms
(milliseconds)
<url> url followed by a string that represents a valid URL in
parentheses, such as url(string)
CSS Properties
alignment-adjust* auto | baseline |
before-edge | text-before-before-edge | middle | central | after-edge | text-after-after-edge | ideographic | alphabetic
| hanging | mathematical
| <percentage> | <length>
Explanation of Values (continued)
Trang 8alignment-baseline* baseline | use-script
| before-edge | text-before-edge | after-edge
| text-after-edge | central
| middle | ideographic
| alphabetic | hanging | mathematical
baseline no
animation* animation shorthand
animation-delay* <time> 0 no
animation-direction* normal | alternate normal no
animation-duration* <time> 0 no
animation-iteration-count* infinite | <integer> 1 no
animation-name* none | IDENT none no
animation-play-state* running | paused running no
animation-timing-function* ease | linear | ease-in |
ease-out | ease-in-out | cubic-bezier
appearance* normal
| <element-name> | inherit normal no
background background shorthand
continues
Trang 9282 Appendix B: CSS Properties
background-attachment scroll | fixed | local scroll no
background-break bounding-box | each-box
| continuous continuous no background-clip* border-box | padding-box border-box no
background-color <color> transparent no
background-image <url> | none none no
background-origin* border-box | padding-box
| content-box padding-box no background-position <percentage> | <length>
| left | center | right | top | bottom
background-repeat repeat | repeat-x | repeat-y
| no-repeat | space | round
repeat no
background-size* <length> | <percentage>
baseline-shift* baseline | sub | super |
<length> | <percentage> baseline no
binding* none | <url> none no
bookmark-label* content | <name> |
<string> content no bookmark-level* none | <integer> none no
CSS Properties (continued)
Trang 10border border shorthand
border-bottom border-bottom shorthand
border-bottom-color <color> current color no
border-bottom-left-radius* <length> | <percentage> 0 no
border-bottom-right-radius* <length> | <percentage> 0 no
border-bottom-style none | hidden | dotted |
dashed | solid | double
| groove | ridge | inset | outset
border-bottom-width <length> | thin | medium| thick medium no
border-collapse collapse | separate |
border-color border-color shorthand
border-image* <url> | none none no
border-left border-left shorthand
border-left-color <color> current color no
border-left-style none | hidden | dotted |
dashed | solid | double
| groove | ridge | inset | outset
border-left-width <length> | thin | medium
border-length* <length> | <percentage> auto no
border-radius* <length> | <percentage> 0 no continues