单行省略:
selector{
-o-text-overflow: ellipsis;/*兼容opera*/
text-overflow: ellipsis;/*这就是省略号喽*/
overflow: hidden;/*设置超过的隐藏*/
white-space: nowrap;/*设置不折行*/
width:200px;/*设置宽度*/
}
多行省略:
因为移动端浏览器用...
分类:
移动开发 时间:
2015-02-06 13:15:50
阅读次数:
211
span标签 当内容超出 强制不断行 自动换行white-space:nowrap;white-space:norma;display:inline-block;超出自动隐藏 英方不断行显示 (必须在块元素内)overflow:hidden;white-space:nowrap;而如果希望在文字后面...
分类:
Web程序 时间:
2015-02-06 11:08:49
阅读次数:
153
CSS2中常用的属性:text-indent:首行缩进;vertical-align:垂直对齐方式;white-space:空格处理方式;line-height:设置行高;CSS3新增文本属性:text-overflow:clip:溢出的部分裁切掉;ellipsis:显示省略标记(...) //该属...
分类:
Web程序 时间:
2015-02-03 14:51:56
阅读次数:
194
.cut { overflow:hidden; white-space:nowrap; text-overflow:ellipsis; -o-text-overflow:ellipsis; -icab-text-overflow: ellipsis; ...
分类:
Web程序 时间:
2015-02-02 19:24:28
阅读次数:
200
多行文本溢出显示省略号(...)的方法现在的浏览器都支持text-overflow:ellipsis属性,用来实现单行文本的溢出显示省略号。如:单行文本:overflow:hidden;white-space:nowrap;text-overflow:ellipsis一些其他技巧可参考:http:/...
分类:
其他好文 时间:
2015-02-02 12:21:15
阅读次数:
177
以下是常用的代码收集,没有任何技术含量,只是填坑的积累。转载请注明出处,谢谢。/*强制不换行*/white-space:nowrap;/*自动换行*/word-wrap: break-word;word-break: normal;/*强制英文单词断行*/word-break:break-all;2...
分类:
Web程序 时间:
2015-01-28 00:43:05
阅读次数:
352
-------------------------------------------------------------------------------说明: White space is defined as the ASCII space character, horizontal tab...
分类:
编程语言 时间:
2015-01-22 01:39:13
阅读次数:
224
一.css2.xcode1.文字换行/*强制不换行*/white-space:nowrap;/*自动换行*/word-wrap:break-word;word-break:normal;/*强制英文单词断行*/word-break:break-all;2.两端对齐text-align:justify...
分类:
Web程序 时间:
2015-01-21 18:00:54
阅读次数:
334
html结构如下:xhtml代码考研英语考研数学考研政治统考专业课试题一开始写的css如下:xhtml代码FF和IE8正常,但在IE6就悲催了...解决方法:自适应宽度的左浮动元素加上display:inline-block;overflow:hidden;white-space:nowrap;xh...
分类:
其他好文 时间:
2015-01-21 14:45:59
阅读次数:
233
1.你不能换行的aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa然后创建一个这样的css样式:.myButton { word-wrap: break-word !important; white-space: normal !important; }然后这将环绕字到该按钮的规...
分类:
其他好文 时间:
2015-01-20 11:41:38
阅读次数:
112