table表格内部有caption,thead,tbody,tfoot这几个结构标签, 也都是配合table标签使用的
标签的语法
这几个标签均应该包裹在table标签内, 且caption应该包裹在thead中
<table border="6">
<thead>
<caption>我的标题</caption>
</thead>
<tbody>
<tr>
<td>100</td>
<td>200</td>
<td>300</td>
</tr>
</tbody>
<tfoot>
<tr>
<td>400</td>
<td>500</td>
<td>600</td>
</tr>
</tfoot>
</table>
标签的作用
其中caption表示整个表格的标题, 会在表格前面且居中表示
另外 caption, thead, tbody, tfoot 这几个标签的解析后的位置是固定的, 也就是说即使你把tfoot写在thead之前, 它解析后的位置也是在thead之后
而 thead, tbody, tfoot没有任何样式, 嵌套前后你无法看出来有什么用, 它只是多一个备选项给css使用的