mar*_*zzz 14 html html-table tablerow
这段代码是否正确?
<table>
<tr>
<td>...</td>
</tr>
<tr>
<div>...</div>
</tr>
<tr>
<td>...</td>
</tr>
</table>
Run Code Online (Sandbox Code Playgroud)
不知道语义(和W3C规则).你能说些什么?
Fel*_*ing 23
不,它无效.tr元素只能包含th和td元素.从HTML4规范:
Run Code Online (Sandbox Code Playgroud)<!ELEMENT TR - O (TH|TD)+ -- table row --> <!ATTLIST TR -- table row -- %attrs; -- %coreattrs, %i18n, %events -- %cellhalign; -- horizontal alignment in cells -- %cellvalign; -- vertical alignment in cells -- >
Alo*_*hci 13
它不仅无效,而且不起作用!这个加价
<table>
<tr>
<td>The First Row</td>
</tr>
<tr>
<div>The Second Row</div>
</tr>
<tr>
<td>The Third Row</td>
</tr>
</table>
Run Code Online (Sandbox Code Playgroud)
生成此显示
The Second Row
The First Row
The Third Row
Run Code Online (Sandbox Code Playgroud)
div完全从表中弹出并放在DOM中
见 http://jsfiddle.net/ELzs3/1/
| 归档时间: |
|
| 查看次数: |
40705 次 |
| 最近记录: |