Top and bottom borders on table row - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Table Row

Description

Top and bottom borders on table row

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 {<!--   ww  w  .j  a va2 s .  c o m-->
   width:100%;
   border-collapse:separate;
   border-spacing:0px;
}

tr {
   background-color:Chartreuse;
}

td {
   width:51%;
   border-top:2px solid yellow;
   border-bottom:2px solid blue;
}
</style> 
 </head> 
 <body> 
  <table> 
   <tbody> 
    <tr> 
     <td>Lo</td> 
     <td>Lo</td> 
    </tr> 
    <tr> 
     <td>Lo</td> 
     <td>Lo</td> 
    </tr> 
    <tr> 
     <td>Lo</td> 
     <td>Lo</td> 
    </tr> 
   </tbody> 
  </table>  
 </body>
</html>

Related Tutorials