HTML table basic
Table in html pages is used to represent data in table format. For this purpose we need following tag.
- <table></table> This tag define html table in webpage.
- <tr></tr> This tag define table row in webpage.
- <th></th> This tag define table heading for row of table
- <td></td> This tag define table data in for each table row
Note
Every heading and data tag in table defines inside the table row.
Every heading and data tag in table defines inside the table row.
Syntex
<table>
<tr>
<th>id</th>
</tr>
<tr>
<td>01</td>
</tr>
</table>
Example| id | name |
|---|---|
| 01 | anna |
| 02 | fanna |
Click to practice online example
Html table has several properties. All html table property provides ability to edit html table according to user.
- border property :
- rowspan property :
- colspan property :
- cellspacing property :
- cellpadding property :
No comments:
Post a Comment