thead
Summary
The thead element (<thead>) identifies header rows at the top of a table, usually containing column labels. It may contain one or more rows of <th> or <td> cells.
Overview Table
Examples
The following code example uses the thead' element and the table, tbody, td, and tr elements to create a table that includes the first row in the table header and the second row in the table body.
<table> <thead> <tr> <th scope="col">Player</th> <th scope="col">Position</th> </tr> </thead> <tbody> <tr> <td>James, Lebron</td> <td>SF</td> </tr> <tr> <td>Wade, Dwayne</td> <td>SG</td> </tr> <tr> <td>Bosh, Chris</td> <td>PF</td> </tr> </tbody> </table>
Notes
Remarks
Valid tags within the THEAD element include:
- td * chances are should be a th not a td, and scope of column
- th
- tr
You can specify only one thead object specified for any given table object. The table object and its associated elements have a separate table object model, which uses different methods than the general object model.
Standards information
- Document Object Model (DOM) Level 2 HTML Specification, Section 1.6.5
- HTML 4.01 Specification, Section 11.2.3
Related specifications
- HTML 5.1
- W3C Working Draft
- HTML 5
- W3C Recommendation
- HTML 4.01
- W3C Recommendation
Attributions
Microsoft Developer Network: [Windows Internet Explorer API reference Article]