我遇到一个相当奇怪的问题。这个问题很小,就是我想将min-height设置为100%,也就是页面内容应该占据整个屏幕,如果可能的话,页面应该在内容超过100%时扩展下去。简单的方法是设置min-height:100%,并将height:auto设置为所需,但无论我尝试多少次,问题仍然存在。
我在所有元素上都使用了height auto和min-height:100%,但它不起作用。如果我只包含height:100%而删除min-height,则它可以完美地工作,但是当内容更多时,它会溢出整个页脚。
请帮帮我,这是CSS:
html, body, container, row, col-lg-3, col-lg-9 {
min-height: 100%;
height: auto !important;
height: 100%;
}
.container {
max-width: 1170px;
min-height: 100%;
height: auto !important;
height: 100%;
}
.col-lg-3 {
min-height:100%;
height:100%;
}
.col-lg-9 {
min-height: 100%;
height: 100%;
}
这里是展示问题的页面: http://contestlancer.com/ai/GP/