- 表格中的行 - html5 表格内容
HTML

元素定义表格中的行。它们可以是和 元素的组合。浏览器支持
所有浏览器都支持
示例
cell a cell b
内容分类 None 允许的内容 零个或多个or元素,或它们的混合
标签省略 开始标记是必填项。如果该元素紧随其后,或者父表组(或)元素不再具有任何内容
,则可以省略End标记
、
允许的父元素 ,
,
or
允许的ARIA角色 任意 DOM接口 HTMLTableRowElement
属性
表格标签支持全局特性。还有一些过期的特性,你应该避免使用它们,但是可以了解它们,会在你阅读旧代码的时候有所帮助。
align
THML5中废弃,THML5中废弃- This enumerated attribute specifies how horizontal alignment of each cell content will be handled. Possible values are:
left
, aligning the content to the left of the cellscenter
, centering the content in the cellsright
, aligning the content to the right of the cellsjustify
, widening the spaces in the textual content so that the content is justified in the cellschar
, aligning the textual content on a special character with a minimal offset, defined by thechar
andcharoff
attributes未实现(查看bug2212)
If this attribute is not set, the parent node's value is inherited.
THML5中废弃。此功能已过时。尽量避免使用它。
char
THML5中废弃,THML5中废弃- This attribute is used to set the character to align the cells in a column on. Typical values for this include a period(.)when attempting to align numbers or monetary values.If
align
is not set tochar
, this attribute is ignored.THML5中废弃。此功能已过时。尽量避免使用它。
valign
THML5中废弃,THML5中废弃- This attribute specifies the vertical alignment of the text within each row of cells of the table header. Possible values for this attribute are:
baseline
, which will put the text as close to the bottom of the cell as it is possible, but align it on thebaselineof the characters instead of the bottom of them. If characters are all of the size, this has the same effect asbottom
.bottom
, which will put the text as close to the bottom of the cell as it is possible;middle
, which will center the text in the cell;- and
top
, which will put the text as close to the top of the cell as it is possible.
Note:Do not use this attribute as it is obsolete(and not supported)in the latest standard: instead set the CSSvertical-align
property on it.
定义和用法
标签定义表格中的行。HTML 4.01 与 HTML 5 之间的差异
在 HTML 5 中,不支持标签的任何属性。实例
一个简单的 HTML 表格,包含两列两行:
month
savings
january
$100
HTML
浏览器支持
所有浏览器都支持
|
示例
cell a | cell b |
内容分类 | None | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
允许的内容 | 零个或多个
| ||||||||||
标签省略 | 开始标记是必填项。如果该
|
内容声明:本文中引用的各种信息及资料(包括但不限于文字、数据、图表及超链接等)均来源于该信息及资料的相关主体(包括但不限于公司、媒体、协会等机构)的官方网站或公开发表的信息。部分内容参考包括:(百度百科,百度知道,头条百科,中国民法典,刑法,牛津词典,新华词典,汉语词典,国家院校,科普平台)等数据,内容仅供参考使用,不准确地方联系删除处理!本站为非盈利性质站点,本着为中国教育事业出一份力,发布内容不收取任何费用也不接任何广告!)