gpt4 book ai didi

html - 使表格 TR 使用全宽和其他正常列

转载 作者:行者123 更新时间:2023-11-28 03:55:44 25 4
gpt4 key购买 nike

我在一个元素中工作,我正在制作一张 table ,看起来像这样:

<table>
<thead>
<tr>
<th>Col 1</th>
<th>Col 2</th>
<th>Col 3</th>
</tr>
</thead>
<tbody>
<tr> <!-- this should be full width -->
<td colspan="3"><span> Very long long text</span></td>
</tr>
<tr>
<td>Col content 1</td>
<td>Col content 2</td>
<td>Col content 3</td>
</tr>
</tbody>
</table>

我希望第一个 tr 是一个全 Angular 元素。现在发生的是 td[colspan="3"] 使用 1 列,因此最后一个 tr 的第一列更大。

编辑

enter image description here

这是一个基本的例子,第一列很长,内容很多,让所有东西都消失在屏幕上

最佳答案

你正在使用 html,所以要更改 css,你需要说:style="colspan:3;"应该有用

关于html - 使表格 TR 使用全宽和其他正常列,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40744425/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com