I would like to always keep the footer at the bottom of my page. I have found code about doing this, such as this for example…
<style>
html,
body {
margin:0;
padding:0;
height:100%;
}
#container {
min-height:100%;
position:relative;
}
#header {
background:#ff0;
padding:10px;
}
#body {
padding:10px;
padding-bottom:60px; /* Height of the footer */
}
#footer {
position:absolute;
bottom:0;
width:100%;
height:60px; /* Height of the footer */
background:#6cf;
}
</style>
<div id=“container”>
<div id=“header”>header</div>
<div id=“body”>body</div>
<div id=“footer”>footer</div>
</div>
This makes sense but being that I have my header, footer, and content in separate views and also attached to separate css files I am not sure what classes I really attach this code too. Should I declare that html, body for all my css files, the header, footer, and main content? I am not sure how I apply this without all parts of my page being in the same file. Please help!
