是否可以在多行文本上使用文本溢出:省略号? [英] Is it possible to use text-overflow:ellipsis on multiline text?

查看:89
本文介绍了是否可以在多行文本上使用文本溢出:省略号?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个 p -tag与特定宽度高度。如果标记中的文本太长,我想使用 text-overflow:ellipsis 来获取 ...

I have a p-tag with a specific width and height. I want to use text-overflow:ellipsis to get ... if the text in the tag is too long. Is this possible to solve with css on multiline text?

推荐答案

Googling并没有揭示任何甚至远在想的东西,所以我

Googling doesn't reveal anything even remotely promising, so I'm going to say that it's not possible.

我发现 text-overflow:-o-ellipsis-lastline 仅适用于Opera http:// people .opera.com / dstorey / text / text-overflow.html (镜像: http://jsbin.com / exugux /

还有一个类似的WebKit解决方案: http://dropshado.ws/post/1015351370/webkit-line-clamp

There's also a similar WebKit-only solution: http://dropshado.ws/post/1015351370/webkit-line-clamp

这篇关于是否可以在多行文本上使用文本溢出:省略号?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆