With css.
Please don't refer me to another link.
EDIT
Make something always at the bottom of viewport no matter how you scroll the bar.
With css.
Please don't refer me to another link.
EDIT
Make something always at the bottom of viewport no matter how you scroll the bar.
If you're having problems specifically with IE6 - consider using a resets script. It will make your life much, much easier. There are lots of different flavours of reset script out there, so do a bit of research and to find one that you like. Personally, I find that yahoo produce one that's fit for purpose.
The thinking behind using a resets script is:
A resets script performs that flattening - and IE6 can be dealt with in a much more logical way.
The obligatory link ;)
http://developer.yahoo.com/yui/reset/
Solution
Bearing in mind the use of this resets script, I offer you the following solution.
As you're probably aware, IE6 doesn't support position:fixed.
To solve the problem you can make use of the following snippet:
<style>
html, body {
height: 100%;
overflow: auto;
}
div#fixed-bottom {
position: fixed;
z-index: 2;
bottom: 0;
height: 20px;
width: 100%;
background-color: #eaeaea;
margin-top: -20px;
}
div#content {
position: relative;
width: 100%;
height: 100%;
overflow: auto;
}
* html div#fixed-bottom {
position: absolute;
}
</style>
Which should be applied to a document containing the following elements within it's <body></body>
:
<div id="fixed-bottom">
<p>
I'm at the bottom
</p>
</div>
<div id="content">
<p>
Your content here.....
</p>
</div>
This should work because:
Note that this solution will only work when IE6 is set to use 'strict mode'. This can be set explicitly by choosing an appropriate doctype; for example:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">