CSS 自动换行属性
原创word-wrap属性用于在一行中断开并换行到下一行。
示例
以下显示了示例语法 −
实时演示
<!DOCTYPE html> <html> <head> <style> div { width: 200px; border: 2px solid #000000; } div.b { word-wrap: break-word; } </style> </head> <body> <h2>word-wrap: break-word property</h2> <div class = "b"> ThisisdemotextThisisdemotext: thisisaveryveryveryveryveryverylongword. The long word wraps to the next line.</div> </body> </html>
输出
以上就是CSS 自动换行属性的详细内容,更多请关注IT视界其它相关文章!
上一篇:使用 CSS 进行绝对定位 下一篇:如何定时自动刷新网页?