Home >Web Front-end >JS Tutorial >JQuery 控制内容长度超出规定长度显示省略号_jquery

JQuery 控制内容长度超出规定长度显示省略号_jquery

WBOY
WBOYOriginal
2016-05-16 16:47:061436browse

长度超出规定长度,显示省略号

设置class为displayPart,

设置自定义属,displayLength可显示长度(不包含...),双字节字符,长度 *2,

复制代码 代码如下:



复制代码 代码如下:




New Document








hello world




hello worldhello worldhello worldhello worldhello worldhello worldhello worldhello worldhello worldhello worldhello worldhello world!!!



hello


hello worldhello worldhello worldhello worldhello worldhello worldhello worldhello worldhelloworldhello worldhello worldhello worldhello worldhello worldhello world



Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn