I am trying to create a head area that is 100px in height and spans 100% in width. I need 2 columns with the left one being 250px wide and 100% in height down to the footer. The right column should be 100% of the remaining page width and 100% in height to the footer. The footer should be at the bottom of the page and 100px in height and 100% in width. Even if there is no content in the 2 columns, I need them to stretch down to the footer and have the footer visible without scrolling down to it.
Here is what I have so far.
<div id="top"><p>Lorem ipsum dolor sit amet</p></div>
<div id="left"><p>Lorem ipsum dolor sit amet</p></div>
<div id="right"><p>Lorem ipsum dolor sit amet</p></div>
<div id="bot"><p>Lorem ipsum dolor sit amet</p></div>
body, html {
height: 100%;
}
body {
margin: 0px;
}
p {
margin: 0px;
}
#top {
height: 100px;
background-color: #F4F4F4;
}
#left {
width: 250px;
height: 100%;
background-color: #878787;
float: left;
margin-bottom: -100px;
}
#right {
background-color: #323232;
height: 100%;
margin-bottom: -100px;
}
#bot {
clear: right;
height: 100px;
background-color: #DCDCDC;
margin-top: -100px;
z-index: 100;
position: relative;
}
Here is another example with a table
<table height="100%" width="100%" cellspacing="0" cellpadding="0" border="0" class="" id="">
<tr>
<td colspan="2" style="background-color: powderblue; height: 100px;">Header</td>
</tr>
<tr>
<td style="background-color: gray; width: 350px;">Left Col</td>
<td style="background-color: DarkSeaGreen">Right Col</td>
</tr>
<tr>
<td colspan="2" style="background-color: tomato; height: 100px;">Footer</td>
</tr>
</table>
