Table, td, div height 100% - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Div Table

Description

Table, td, div height 100%

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">
html {<!--from  w w w .  j  av  a  2s . c o m-->
   height:100%;
}

body {
   height:100%;
}

#container {
   height:100%;
   width:100%;
}

#sinistra {
   min-height:100%;
   width:21%;
   border:2px solid Chartreuse;
}

#centro {
   min-height:100%;
   border:2px solid yellow;
}

#destra {
   min-height:100%;
   width:21%;
   border:2px solid blue;
}

table, table tr {
   width:100%;
   min-height:100%;
}

#divsinistra,#divcentro,#divdestra {
   min-height:100%;
}
</style> 
 </head> 
 <body> 
  <div id="container"> 
   <table> 
    <tbody> 
     <tr> 
      <td id="sinistra"> 
       <div id="divsinistra">
         Lorem ipsu 
       </div> </td> 
      <td id="centro"> 
       <div id="divcentro">
         Lorem ip 
       </div> </td> 
      <td id="destra"> 
       <div id="divdestra">
         Lorem ip 
       </div> </td> 
     </tr> 
    </tbody> 
   </table> 
  </div>  
 </body>
</html>

Related Tutorials