看看这张图片...
http://www.flickr.com/photos/91733140@N06/8329388242/in/photostream
如何让这个 div 向左而不是向右?
它一直在搞砸,我真的需要修复它,我有什么想法可以让它工作吗?
<style type="text/css">
#body {
height: 100%;
margin: 0;
padding: 0;
}
#html, body {
height: 100%;
margin: 0;
padding: 0;
background: #E0E0E0;
}
#header {
background: #FFFFFF;
height: 33px;
width: 100%;
padding: 5px 30px 5px 30px;
font-family: arial;
font-size: 30px;
border-bottom: 1px #737373 solid;
position: fixed;
top: 0;
}
#container {
width: 1205px;
margin-left: auto;
margin-right: auto;
margin-top: 50px;
}
#box {
width: 228px;
height: auto;
background: #FFFFFF;
border: 1px #5E5E5E solid;
margin: 5px;
float: left;
font-family: arial;
}
#box_title {
width: 218px;
height: auto;
padding: 5px;
background: #5E5E5E;
color: white;
border-bottom: 1px #FFFFFF solid;
float: left;
font-family: arial;
}
#box_img {
width: 210px;
height: auto;
float: left;
margin-left: auto;
margin-right: auto;
}
#box_options {
width: 228px;
height: 40px;
background: #FFFFFF;
color: #000000;
border-top: 1px #5E5E5E solid;
float: left;
font-family: arial;
最佳答案
不是通过你打开的标签来判断你,但你似乎想要一个“Pinterestish”墙。这通过 vanilla css 并不容易,我可以建议研究一下 jquery masonry 吗?
它为你做了所有繁重的工作
关于css - 我怎样才能让这个 div 向左而不是向右?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14099127/