-->

HTML with colspan and rowspan

another example of rowspan and colspan is given below.
---------------------------------------------------------------------------------------------------
<html> <!--called root tag-->
<head> <!--used for meta tag-->
<title><!-- it is for title tag-->
understanding table tag with rowspan and colspan
</title>
</head>
<body><!-- is container-->
<!--following tag is used as heading-->
<h1>we are going to creat table</h1>
<!-- we are going to create table-->
<table border="1" width="100%" bordercolor="green">
<caption align="top">student's details</caption>
<tr>
<td>six</td>
<td>seven</td>
<td>eight</td>
<td>nine</td>
</tr>
<tr>
<!--merges two rows and columsn -->
<td colspan=2 rowspan=2 bgcolor="purple">two</td>
<td>three</td>
<td>one</td>
</tr>
<tr>
<td>four</td>
<td>five</td>
</tr>

</table><!--closing of table-->
</body> <!--closing of body-->
</html> <!--closing of html-->

 

No comments:

Post a Comment