Demo: Jsfiddle
HTML
<body> <div style="height:100%"> <div class="topdiv">top div</div> <div class="bottomdiv">bottom div</div> </div>
CSS
body {margin:0;padding:0;height:100%;} div.topdiv {clear:both;position:fixed;top:0;height:50%;width:100%;background-color:#990000;color:#FFFFFF;font-size:16px;text-align:center;} div.bottomdiv {clear:both;position:fixed;bottom:0;height:50%;width:100%;background-color:#009900;color:#FFFFFF;font-size:16px;text-align:center;}β
source share