How to have a table cell that spans two rows in HTML?

 Posted by Pgayath on 9/21/2012 | Category: HTML 5 Interview questions | Views: 1333 | Points: 40
Answer:

The <rowspan> tag is used to span two rows.

Example:
<html>

<body>
<h4>Cell that spans two rows:</h4>
<table border="1">
<tr>
<th>First Name:</th>
<td>Charles Babbage</td>
</tr>
<tr>
<th rowspan="2">Telephone:</th>
<td>555 82 982</td>
</tr>
<tr>
<td>555 86 986</td>
</tr>
</table>

</body>
</html>


| Alert Moderator 

Comments or Responses

Login to post response