Add caption to table - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Table Caption

Description

Add caption to table

Demo Code

ResultView the demo in separate window

<html lang="en">
 <head> 
  <style>
#myTable caption {
   caption-side:bottom;
}

tr, td, th {
   border:2px solid Chartreuse;
}
</style> <!--  w ww  .jav a 2  s . c o m-->
 </head> 
 <body translate="no"> 
  <table id="myTable"> 
   <thead> 
    <tr> 
     <th>Lore</th> 
     <th>Lore</th> 
    </tr> 
   </thead> 
   <tbody> 
    <tr> 
     <td>Lore</td> 
     <td>Lore</td> 
    </tr> 
   </tbody> 
   <caption>
     Lorem ipsum dolor sit amet, c 
   </caption> 
  </table>  
 </body>
</html>

Related Tutorials