Sunday, October 15, 2017

CLASS 6 - DIFFERENCES BETWEEN CELLSPACING AND CELLPADDING IN HTML

What is cell-spacing & cell-padding? How we create those things in HTML?

<table>, <tr>, <th>, <td>, cell-spacing, cell-padding elements are used in HTML for padding and spacing in table.

File Name:  "Table.html"

<html>
<head>
<title>HTML TABLE PROGRAM</title>
</head>
<body>
<br/> <br/> <br/>
<table border="1" align="center" width="200" cellspacing="50" cellpadding="100">
<tr>
<th bgcolor="yellow">S.No</th>
<th bgcolor="yellow">Name</th>
</tr>
<tr>
<th align="center" bgcolor="lime">1</th>
<th align="center" bgcolor="lime">Anil</th>
</tr>
<tr>
<th align="center" bgcolor="skyblue">2</th>
<th align="center" bgcolor="skyblue">Sunil</th>
</tr>
</table>
</body>
</html>

OUTPUT:


 Watch the below video for more details on the above program:




*************************************************************************

No comments:

Post a Comment