我想扩展我的左侧边栏,使它跨越页面的长度(或容器DIV)。我尝试将容器的高度设置为100%,然后将侧边栏的高度设置为100%,但这不起作用。扩展它的容器长度的div
这里是我的编码:
div#container
{
overflow: hidden;
margin-left: auto;
margin-right: auto;
margin-top: 0px;
padding-bottom: 10px;
width: 880px;
height: 100%;
text-align: left;
}
div#left
{
float: left;
width: 280px;
height: 100%;
padding: 4px;
background: #F1D7A5;
}
这里是页面的样子:http://www.studentbridges.org/new/
我如何能延长侧边栏的任何输入将不胜感激!
谢谢!
〜Noelle
但是,根据某人正在查看的网页,容器的长度可变。尽管侧栏设置为100%,但容器仍然长于栅栏。 也许我不理解你。 – nellygrl 2012-07-27 20:20:37
#left div不是直接在#container里面,它在#container里面#contbg,#contbg只给出#container没有被#header占用的空间。 – Austin 2012-07-27 20:26:53
哦。我想如果我把它们全部设置为100%,它会延伸到页面上。我猜不会。 你知道我该如何补救吗?或者我刚刚运气不好? – nellygrl 2012-07-27 20:33:57