Set table to 70% td to 50% - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Table Cell

Description

Set table to 70% td to 50%

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">
table {<!--from  w  w w.j  a  v  a  2  s. c om-->
   margin:0 auto;
   border-spacing:16px;
   width:71%;
   min-height:251px;
   table-layout:fixed;
}

td {
   padding:11px;
   background-color:Chartreuse;
   width:51%;
   overflow:hidden;
}
</style> 
 </head> 
 <body> 
  <table> 
   <tbody> 
    <tr> 
     <td>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi ullamcorper molestie lacus sed fermentum. Aliquam erat volutpat. Vestibulum tortor neque, ornare vitae tempor hen</td> 
     <td>Lorem ipsum dolor sit amet, consectetur ad</td> 
    </tr> 
    <tr> 
     <td>Lore</td> 
     <td>Lorem i</td> 
    </tr> 
   </tbody> 
  </table>  
 </body>
</html>

Related Tutorials