Make div's height 100% - HTML CSS CSS Layout

HTML CSS examples for CSS Layout:Height

Description

Make div's height 100%

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <style type="text/css">
body, html {
   height:100%;
   margin:0px;
}

#myDiv {<!--   w w w. ja  v a  2s. co m-->
   height:100%;
   background:red;
}
</style> 
 </head> 
 <body> 
  <div id="myDiv"></div>  
 </body>
</html>

Related Tutorials