Define the table title and briefly describe the table.
Note:
The caption element should be a sub-object of the table element.
Table objects and their associated elements have an independent table object model. This mode uses a different method than the conventional object model. For more information about the table object model, see how to dynamically generate a table.
This element is available in HTML of Internet Explorer 3.0 and later versions, and in scripts of Internet Explorer 4.0 and later versions. 1. It is an embedded element; 2. This element needs to be closed.
Code:
<HTML>
<Body>
<H4>
Code running result
This table has the title:
</H4>
<Table border = "6">
<Caption> table title </caption>
<Tr>
<TD> 100 </TD>
<TD> 200 </TD>
<TD> 300 </TD>
</Tr>
<Tr>
<TD> 400 </TD>
<TD> 500 </TD>
<TD> 600 </TD>
</Tr>
</Table>
</Body>
</Html>