强制列大小尽可能最小
我有一个表,其中包含信息,最后一列中有一个执行功能的图标。我想知道是否可以强制该列尽可能小(即与图标一样宽)。目前它有相当多的空白区域我无法摆脱。我尝试将宽度设置为 1% 和 1px。我如何强制它变小?
谢谢
I have a table with information in it and an icon in the last column that perfoms a function. I was wondering if it were possible to force that column to be as small as possible (i.e. as wide as the icon). Currently it has a fair bit on white space that i cant get rid of. I have tried setting the width tp 1% and 1px. How to i force it smaller?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
你的表格宽度设置为 100%,不是吗?尝试在带有空白单元格的图标列之后添加另一列,看看这是否不会占用一些额外的宽度。
Your table width is set to 100%, no? Try adding another column after your icon column with blank cells and see if that does not take some of the extra width away.
将 TD 标签的宽度设置为与 IMG 标签(图标)的宽度相同,如下代码:
Set width for TD tag as same as width for IMG tag(icon), like this code:
<td width="16"><img width="16" ... />