w3pop.com :: 网络学院 :: HTML :: HTML <caption>标签
This element defines a table caption. The <caption> tag must be inserted immediately after the <table> tag. You can specify only one caption per table. Usually the caption will be centered above the table.
这个元素可以给表格定义标题,<caption>标签必须在<table>标签后立即插入。你可为每个表格指定唯一的一个标题。一般情况下标题会出现在表格的上方
The "align" attribute of the caption element was deprecated in HTML 4.01.
caption元素的"align"的属性在HTML4.01中不被推荐
The "align" attribute of the caption element is not supported in XHTML 1.0 Strict DTD.
在XHTML严密型DTD中"align"属性已经不被支持
| 源代码 | 输出结果 | ||
|---|---|---|---|
|
<table border="1"> |
|
DTD indicates in which DTD the attribute is allowed. S=Strict, T=Transitional, and F=Frameset.
下表中的DTD列指明了被支持的DTD属性。S=Strict(精确的),T=Transitional(传统的),F=Frameset(框架)
| 属性 | 值 | 描述 | DTD |
|---|---|---|---|
| align | left right top bottom |
How to align the caption. Deprecated. Use styles instead. 对齐标题。[不推荐]使用样式取代 |
TF |
| id, class, title, style, dir, lang, xml:lang |
For a full description, go to Standard Attributes.
查看完整描述
| onclick, ondblclick, onmousedown, onmouseup, onmouseover, onmousemove, onmouseout, onkeypress, onkeydown, onkeyup |
For a full description, go to Event Attributes.
查看完整描述
Table with a caption
This example demonstrates a table with a caption.
一个带有标题的表格
评论 (0)
All