简体   繁体   English

不要在表格 html 中使用 colspan 或 rowspan

[英]Don't work colspan or rowspan in table html

I don't span cells cell1_1 and cell1_2 .我不跨越单元格cell1_1cell1_2 When I'm using colspan="2" at #cell1_1 it don't work.当我在#cell1_1使用colspan="2" ,它不起作用。 My example I try use method at jsfiddle ,but don't work tag br when I use rowspan.我的例子我尝试在jsfiddle使用方法,但是当我使用 rowspan 时不工作标记br
I don't understand how working skipping cells?我不明白跳过单元格是如何工作的?
But can't find solution!但是找不到解决办法! Please help!请帮忙!

Your colspan="2" works fine.您的colspan="2"工作正常。 The problem is that there is no other cell that's only in column #2.问题是没有其他单元格在第 2 列中。 So the browser makes column 2 very small.所以浏览器使第 2 列非常小。

Try adding this row at the end and you'll see it start working:尝试在最后添加这一行,你会看到它开始工作:

<tr class="row10">
  <td>10_1</td>
  <td>10_2</td>
  <td>10_3</td>
  <td>10_4</td>
  <td>10_5</td>
  <td>10_6</td>
</tr>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM