我试图修改一个棘手的页脚(http://www.cssstickyfooter.com/)表现出保证金...很容易对左右宽度为:90%和保证金:汽车CSS浮动页脚边距
| | | |
| | | |
| | | |
| | | |
但如何获得高度的90%(或表现出某种顶部&下边距)不会弄乱浮动页脚
| ____ |
| | | |
| |____| |
| |
感谢
body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,form,fieldset,input,
textarea,p,blockquote,th,td {
margin:0;
padding:0;
}
#header {
height: 33px;
line-height: 33px;
text-align: center;
background-color: green;
}
html { height: 100%; }
body { height: 100%; width: 90%; margin: auto; }
#wrap { min-height: 100%; background-color:gray; }
#main {
overflow: auto;
padding-bottom: 33px; /* must be same height as the footer */
background-color: red;
height: 100%;
}
#footer {
position: relative;
margin-top: -33px; /* negative value of footer height */
height: 33px;
line-height: 33px;
text-align: center;
background-color:blue;
}
html {height:90%;利润率:5%;利润率下限:5%; }不起作用!?顶部是罚款,但底部延伸错了 – 2010-08-08 18:52:07
http://jsfiddle.net/F9HBc/为什么这么难以垂直集中_stretching_ div?它处理horozontal调整大小罚款(无论我是愚蠢的,给定...或css是) – 2010-08-09 14:32:20
http://www.jsfiddle.net/CrdEy/基于http://www.infinitywebdesign.com/research/cssverticalcentereddiv.htm 仍然无法正常工作 – 2010-08-09 14:32:59