Return to Snippet

Revision: 48563
at July 5, 2011 07:26 by lister


Initial Code
The HTML

<div id="wrap">
<div id="main" class="clearfix">
</div>
</div>
<div id="footer">
</div>

The CSS

  * { margin:0; padding:0; }
html, body, #wrap { height: 100%; }
body > #wrap {height: auto; min-height: 100%;}
#main { padding-bottom: 150px; }  /* must be same height as the footer */
#footer {
position: relative;
margin-top: -150px; /* negative value of footer height */
height: 150px;
clear:both;}
/* CLEAR FIX*/
.clearfix:after {content: ".";
display: block;
height: 0;
clear: both;
visibility: hidden;}
.clearfix {display: inline-block;}
/* Hides from IE-mac */
* html .clearfix { height: 1%;}
.clearfix {display: block;}
/* End hide from IE-mac */

Initial URL

                                

Initial Description

                                

Initial Title
Sticky Footer (make footer always be on bottom without absolute positioning)

Initial Tags

                                

Initial Language
CSS