Add a fixed height header with a div that takes up 100% of the remaining space - HTML CSS CSS Layout

HTML CSS examples for CSS Layout:Height

Description

Add a fixed height header with a div that takes up 100% of the remaining space

Demo Code

ResultView the demo in separate window

<html>
 <head></head> 
 <body> 
  <div style="height:60px; position:fixed; width:100%;"></div> 
  <div style="height:100%; width:100%;"> 
   <p style="padding-top:60px;">hola</p> 
  </div>  <!--from w  w w  .java 2s . c  o m-->
 </body>
</html>

Related Tutorials