Click to See Complete Forum and Search --> : Bottom aligning a div


Blazeix
07-25-2006, 03:49 PM
Hi. I'm trying to make a div that will be at the bottom of the page (the page will not be scrollable, so it just needs to be initially placed there). This is what I have so far, and it doesn't work.


<style type="text/css">
<!--
#container {
height:100%;
}

#bottom{
vertical-align: bottom;
}
-->
</style>
...
<div id="container">
<div id="bottom">
This should be at the bottom of the page!
</div>
</div>


Can anyone help? I've searched around, and there doesn't seem to be much on this subject, unless I'm looking in the wrong places. Thanks.

KDLA
07-25-2006, 04:03 PM
#bottom {position: absolute; bottom: 0;}

You may have to tweak that value.

Reference: http://www.w3schools.com/css/css_reference.asp#positioning