table elements html code example
Example 1: table html
<table>
<thead>
<tr>
<th>header1</th>
<th>header2</th>
<th>header3</th>
</tr>
</thead>
<tbody>
<tr>
<td>text1.1</td>
<td>text1.2</td>
<td>text1.3</td>
</tr>
<tr>
<td>text2.1</td>
<td>text2.2</td>
<td>text2.3</td>
</tr>
<tr>
<td>text3.1</td>
<td>text3.2</td>
<td>text3.3</td>
</tr>
<tr>
</tr>
</tbody>
</table>
Example 2: table css
tr , th , td {
border: 1px solid black;
padding: 5%;
text-align: center;
}
Example 3: table html tages
<table>
<tr>
<th>This is the heading</th>
<th>Next heading to the right</th>
</tr>
<tr>
<td>This is where the table data goes</td>
<td>This is the second columns data</td>
</tr>
</table>
Example 4: html tables
<table></table>
<td></td>
<tr></tr>
<th></th>
<thead></thead><tbody></tbody><tfoot></tfoot>
<tr rowspan="2"></tr>
<tr colspan="2"></tr>