ⓘ th – table header cell # T
The
th
element represents
a header cell in a table.
Permitted attributes #
-
ⓘ
global attributes
- Any attributes permitted globally.
-
ⓘ
scope =
"row"
or "col"
or "rowgroup"
or "colgroup"
#
- Specifies what set of cells the
th
element applies to.
-
ⓘ
colspan =
positive integer
#
- Specifies the number of adjacent columns “spanned” by
its
th
element.
-
ⓘ
rowspan =
non-negative integer
#
- Specifies the number of following rows “spanned” by
its
th
element.
- Identifies one or more
th
elements that apply to its
th.
Additional constraints and admonitions #
-
The scope attribute on the td element is obsolete.
Use the scope attribute on a th element instead.
-
The abbr attribute on the th element is obsolete.
Consider instead beginning the cell contents with concise text, followed by further elaboration if needed.
-
The axis attribute on the th element is obsolete.
Use the scope attribute instead.
-
The align attribute on the th element is obsolete.
Use CSS instead.
-
The width attribute on the th element is obsolete.
Use CSS instead.
-
The char attribute on the th element is obsolete.
Use CSS instead.
-
The charoff attribute on the th element is obsolete.
Use CSS instead.
-
The valign attribute on the th element is obsolete.
Use CSS instead.
-
The bgcolor attribute on the th element is obsolete.
Use CSS instead.
-
The height attribute on the th element is obsolete.
Use CSS instead.
-
The nowrap attribute on the th element is obsolete.
Use CSS instead.
Permitted parent elements #
tr
Typical default display properties #
th {
display: table-cell;
vertical-align: inherit; }
th {
font-weight: bold;
text-align: center; }