I tested this in IE7 / 8 (not 6!) And the latest versions: Firefox, Chrome, Opera.
Live Demo (complete with boring colors)
HTML is very simple:
<div id="header">header</div> <div id="middle"> <div id="left">left</div> <div id="right">right</div> </div> <div id="footer">footer</div>
CSS , on the other hand, is a bit more complicated:
html, body { margin: 0; padding:0; border: 0; overflow: hidden } #header, #middle, #footer { position: absolute; width: 100% } #header { background: #777; height: 150px; top: 0 } #middle { background: #f00; top: 150px; bottom: 150px } #footer { background: #777; height: 150px; bottom: 0 } #left, #right { overflow-y: scroll } #left { background: #aaa; position: absolute; left: 0; top: 0; width: 50%; height: 100% } #right { background: #999; position: absolute; left: 50%; top: 0; float: right; width: 50%; height: 100% }
I will explain how CSS works if you ask me.
source share