Table to div: adapting width - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Div Table

Description

Table to div: adapting width

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">
.column {<!--from   ww  w. ja  v  a2s  . c o  m-->
   float:left;
   margin:11px;
   border:2px solid Chartreuse;
   padding:6px;
}

.row {
   border:2px solid yellow;
   padding:6px;
   margin:6px;
}
</style> 
 </head> 
 <body> 
  <div class="column"> 
   <div class="row"> 
    <p>Lorem ipsum </p> 
   </div> 
   <div class="row"> 
    <p>Lorem ipsum dolor sit amet, </p> 
   </div> 
  </div> 
  <div class="column"> 
   <div class="row"> 
    <p>Lorem ipsum </p> 
   </div> 
   <div class="row"> 
    <p>Lorem ipsum </p> 
   </div> 
  </div>  
 </body>
</html>

Related Tutorials