html的相關知識
阿新 • • 發佈:2018-12-07
ima .com border text amp 只顯示一行 ont kit space
盒子模型:
content:內容
padding:用於控制內容與邊框的距離.
margin:用於控制元素與元素間的距離.
border:邊框距離.
背景:
background-position:背景定位(x y)
background-img:圖片路徑url()
backdround-repeat:{ no-repeat圖片不重復 repeat圖片重復且鋪滿 }
復合樣式:background:url() repeat x y ;
文本溢出:
1、在容器裏只顯示一行文字文本溢出顯示...的方法
text-overflow:ellipsis;
overflow:hidden;
white-space:nowarp;
2、在容器裏顯示多行並隱藏
text-overflow:ellipsis;
overflow:hidden;
display:-webkit-box;
-webkit-box-orient:vertical;
-webkit-line-clamp:10 *你需要顯示的行數.
html的相關知識