Add border to table TD - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Table Border

Description

Add border to table TD

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,td{
   border: 1px solid black;
   padding: 5px;
   margin: 1px;
}


      </style> 
 </head> <!--from   www  .  j  a  va 2  s  .co m-->
 <body> 
  <table border="10" cellpadding="10" cellspacing="10" style="width: 800px;border-collapse: collapse;"> 
   <tbody style="border: 1px solid black; "> 
    <tr> 
     <td> <span style="color:#000000;"> <span style=""> <strong>ID Number</strong> </span> </span> </td> 
     <td> <span style="color:#000000;"> <span style=""> <strong>Room Name</strong> </span> </span> </td> 
     <td> <span style="color:#000000;"> <span style=""> <strong>Name of Company</strong> </span> </span> </td> 
    </tr> 
    <tr> 
     <td> <span style="color:#000000;"> <strong> <span style="">1</span> </strong> </span> </td> 
     <td> <span style="color:#000000;"> <span style="">Premier</span> </span> </td> 
     <td> Amsh Ltd</td> 
    </tr> 
   </tbody> 
  </table>  
 </body>
</html>

Related Tutorials