I have the following layout for my web page. The following CSS code gives me 100% height and width in Internet Explorer 9. While the same gives me 100% width in FF and Chrome, but not at 100% height. I tried several examples, most of them have the same problem. I use the same code at http://jsfiddle.net/cwkzq/3/ here, if I see the same as FF, it gives me 100% height and width.
<html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title></title> <style type="text/css"> html, body { height: 100%; } body { margin: 0; padding: 0; border: 1; background-color:Aqua; } .Container { width: 100%; height: 100%; border: solid 1px red; margin: 0 auto; padding: 0 1em; font: 12px/1.5 Verdana; background-color:red; } </style> </head> <body> <form id="form1" runat="server"> <div class="Container"> <div class="colorBar"> asd </div> <div class="MiddleWrapper"> <div class="Title"> </div> <div class="ImageLeftWrapper"> </div> <div class="LogoWrapper"> </div> <div class="PageText"> </div> <div class="SearchBar"> </div> <div class="BannerImageWrapper"> </div> </div> <div class="MenuWrapper"> </div> <div class="FooterWrapper"> </div> </div> </form> </body> </html>
I would appreciate if someone could point out a problem in the code.
source share