css實現單行文本和多行文本省略號

單行文本出現省略號的條件:css <style> p { width: 200px; /*寬度*/ text-overflow: ellipsis; /*文字以省略號的方式隱藏*/ white-space: nowrap;/*禁止文字內容折行*/ overflow: hidden;/*超出部分溢出隱藏*/ } </style> <p>單行文本出現省略號單
相關文章
相關標籤/搜索