Html table row cell attributes

The tr element makes row of table cells and td makes cells of table that contains data. For example
<table>
<tr><td>Row 1 Cell 1</td> <td>Row 1 Cell 2</td><td>Row 1 Cell 3</td></tr>
<tr><td>Row 2 Cell 1</td> <td>Row 2 Cell 2</td><td>Row 2 Cell 3</td></tr>
</table>

  The result table is as:

Row 1 Cell 1 Row 1 Cell 2 Row 1 Cell 3
Row 2 Cell 1 Row 2 Cell 2 Row 2 Cell 3

We may set header information with th element.When we use th element for header information, by default it makes text bold and keeps alignment center  as in example

<table>
<tr><th>Name</th> <th>Email</th><th>Phone</th></tr>
<tr><td>Mr. Khanna</td> <td>khanna123@gmail.com</td><td>9635666666</td></tr>
</table>

Result:

Name Email Phone
Mr. Khanna khanna123@gmail.com 9635666666

We may span rows by using colspan attribute

<table>
<tr><th>Name</th> <th>Email</th><th>Phone</th></tr>
<tr><td colspan="2">Mr. Khanna khanna123@gmail.com</td><td>9635666666</td></tr>
</table>

Name Email Phone
Mr. Khanna khanna123@gmail.com 9635666666

In above example we see second row's first cell spans two columns because its colspan is set 2.
In a same way we may span cell row-wise by using attribute rowspan
 
<table>
<tr><th>Name & Email</th><th>Phones</th></tr>
<tr><td rowspan="2">Mr. Khanna  </td><td>9635666666</td></tr>
<tr><td>96356623232</td></tr>
</table>


Name & Email Phones
Mr. Khanna 9635666666
96356623232