单行文本溢出显示省略号:
style{
p{
width:100%;height:50px;
display:block;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
-o-text-overflow: ellipsis;
}
}
多行文本溢出显示省略号:
style{
p{
width:100%;height:50px;
display: -webkit-box;
-webkit-line-clamp: 2;<--要显示的行数-->
-webkit-box-orient: vertical;
overflow: hidden;
text-overflow: ellipsis;
-o-text-overflow: ellipsis;
}