How to stack divs from top to bottom in CSS

前端 未结 3 1036
感动是毒
感动是毒 2020-12-01 21:28

I have a list that goes like this:

1
2
3
&l
3条回答
  •  北海茫月
    2020-12-01 22:12

    @ funky; you can use css3 column-count property for this

    css:

    div#multicolumn1 {
            -moz-column-count: 2;
            -moz-column-gap: 50%;
            -webkit-column-count: 2;
            -webkit-column-gap: 50%;
            column-count: 3;
            column-gap: 50%;
    
    }
    

    check this link for a demo Div's in two columns

    http://jsfiddle.net/sandeep/pMbtk/

    note: it doesn't work in IE.

提交回复
热议问题