- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我正在尝试使用 text-overflow:ellipsis
在<td>
里面标签,但它只支持 <div>
标签。
支持 <td>
的想法标签?
最佳答案
我已经通过使用 max-width
找到了解决方案
<style>
.test
{
white-space:nowrap;
text-overflow:ellipsis;
max-width: 100px;
overflow:hidden;
border:1px solid #000000;
}
</style>
</head>
<body>
<table border="1">
<tr>
<td class="test">
This is the Long text only applied to div tag
</td>
</tr>
</table>
</body>
关于php - CSS 用 "..."打断长文本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18826259/
我正在使用原味 Markdown ,如here所述. 我想知道是否可以在 Markdown 代码中打断长行,同时不会产生语法效果。 (在其他语言中,例如 shell 脚本和 C,\ 将用于继续下一行。
我在显示从 0-10K 运行的图时遇到了问题。目前我有从 0-100 运行的计算,它看起来很棒。 目前: 现在我想加一个 X 点,也就是 10K它看起来是这样的: 如何将它保持在 0-100 之间,然
我在更广泛的范围内问这个问题,因为我现在没有面临这个具体问题,但我想知道将来该怎么做。 如果我有一个长时间运行的 python 脚本,它应该一直在做某事(如果有帮助的话,可以是一个无限循环)。通过在终
主题:利用python画图实现坐标轴截断或打断 关键词:python, plot, matplotlib, break axes 方法一: 首先介绍一种简单快速的方法――调用包 brokena
如果运行此代码并单击 P,整个捕获阶段将执行,但冒泡阶段将按预期在 div 上停止。这段代码有什么问题? for(let elem of document.querySelectorAll('*'
那是通常的“让 img 旁边的东西垂直居中”,但我需要两行。一行就好了,但看起来像 破坏它。 Centered text 结果: IMG IMG text here IMG 但是如果我想这样做:
我在 GNU/Linux 下用 C 语言编程的多线程服务器中有这种奇怪的行为。当它正在发送数据时,最终会被 SIGPIPE 中断。因此,我设法忽略了 send() 中的信号并在每次操作后处理 errn
我有一个 ListView,它有一个方法 (public ArrayAdapter populateListView(){}) 来更新适配器。我每 500 毫秒调用一次 lv.setAdapter(p
我想将 div 堆叠在一起并在三个子元素之后打断 div。 示例 HTML: hello hello hello hello hello hello
我是一名优秀的程序员,十分优秀!