Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
CSS Trickstery
Usually I solve these kinds of problems, but I think this time I have been staring the code way too long since I just can't figure out what gives.
Basically the problem is that I have two sections wrapped in divs, one is navigation and one is the main section where all the data is presented. The Navigation is supposed to start right from the top of the window and the main section is supposed to start 60px down.
But for some reason the main section is dragging the navigation section down with him, and I just don't know why it is doing that. The solution to this might just be stupid easy but I'm just can't seem to figure it out.
Basically the problem is that I have two sections wrapped in divs, one is navigation and one is the main section where all the data is presented. The Navigation is supposed to start right from the top of the window and the main section is supposed to start 60px down.
But for some reason the main section is dragging the navigation section down with him, and I just don't know why it is doing that. The solution to this might just be stupid easy but I'm just can't seem to figure it out.
#sidebar
{
position: absolute;
left: 0;
width: 170px;
padding-left: 20px;
padding-right: 20px;
}
#content
{
font-size: 100%;
margin: 60px 0px 0 210px;
padding: 0px 20px 0 20px;
width: 60%;
}
0
This discussion has been closed.
Comments
The succesfully top aligned sidebar doesn't play nice with my footer, since the sidebar isn't floated and it's position is absolute the footer will slide right under it and clear:both; doesn't help a bit.
Problem shown below (sorry if the image is too big.)
you could put a height on #content, but i would have thought you would want that to grow/shrink with the text. you may get away without putting a height on the content div if you can be sure there will always be enough text in there to clear your sidebar.