HyperText Markup Language
What's New in 3.2?


HTML Tables

HTML Table Tags

Attributes for the <TABLE> Tag

Attributes for the <TR> Tag

Attributes for the <TH> and <TD> Tags

Examples

Attributes for the <CAPTION> Tag

The <CAPTION> tag must appear directly after the opening <TABLE> and before the first <TR> tag

Example: Complex Table Code Using Caption

<TABLE BORDER=2 WIDTH="90%">
<CAPTION>Caption: Table with Merged Cells</CAPTION>
<TR><TH ROWSPAN=2></TH>
<TH COLSPAN=2>Average</TH>
<TH ROWSPAN=2>other<BR>category</TH>
<TH>Misc</TH></TR>
<TR><TH>height</TH><TH>weight</TH></TR>
<TR><TH ALIGN=LEFT>males</TH><TD>1.9</TD> <TD>0.003</TD></TR>
<TR><TH ALIGN=LEFT ROWSPAN=2>females</TH> <TD>1.7</TD><TD>0.002</TD></TR>
</TABLE>

Displays as:

Caption: Table with Merged Cells
Average other
category
Misc
heightweight
males1.9 0.003
females 1.70.002


Go to:


Library of Congress
Library of Congress Help Desk (07/13/99)