Search DaTutorials:  
HOME
Html Tutorials
Basics
Forms
Frames
Hyperlinks and URLS
Images
Lists
Background
Colors
Fonts
Tables
Meta Tags
Events
Javascript Integration
Sound
Other
Search For a Tutorial
Html Reference

Table with a caption

Description:


How to create table with a caption in an html page.

Code:

<html>
<body>


<table border="10">
<caption>Table 1</caption>
<tr>
  <td>cell 1</td>
  <td>cell 2</td>
  <td>cell 3</td>
</tr>
<tr>
  <td>cell 4</td>
  <td>cell 5</td>
  <td>cell 6</td>
</tr>
</table>


</body>
</html>

Play with the code:

See working example:


Explanation:

To stick a label on the table, use the <caption></caption> tag and place it right after the <table> tag.

See Also:

HTML: Html, Body, Table, Tr, Td, Caption


Online Html Forum  Discuss this tutorial in our HTML forum


     Loans | Car Insurance | Quick Collect | Loans | Mortgages
Home     Link To Us     Ad With Us     Contact Us     Tell A Friend     Affiliates     Blog     MsOfficeHelp