css3-columns multi-column layout_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:46:45
Original
1625 people have browsed it

 1 /*css3中的布局*/ 2 .wrapper{ 3    margin:auto; 4    width:300px; 5    height:200px; 6    border:2px dotted blue; 7    -webkit-columns:15px 3;/*表示多列布局,每一列15px 有3列,内容多于3列则该参数失效!例如对一篇文章可以进行多列布局显示*/ 8       9      -webkit-column-count:3;10      -webkit-column-width:15px;/*将width和count属性拆开来单独使用,弱拆开且同时使用,浏览器根据具体情况会可能会使某一属性失效*/ 11      -webkit-column-gap:2em;/*设置列间距为2字符,不设置默认情况下为1字符间距*/    12 13     -webkit-column-rule:2px    solid red;/*定义列与列之间的分割线为2px  实体  红色 该分割线不占用空间位置 like a ghost*/14     15 }16 h2{17    text-align:center;/*文本居中显示*/18    -webkit-column-span:all;/*令h2横跨所有列*/19 }
Copy after login

 

Related labels:
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!