The cellpadding attribute of the TABLE element specifies the cell padding (the space within cells).
<table cellpadding="3">
| Attribute | Value | Explanation |
|---|---|---|
| cellpadding=" " | pixels or % | the size of the padding |
This can be specified with CSS. Please see the "Related Document" for details on CSS.
The cellpadding is 0
<table border="1" cellpadding="0">
<tr>
<td>Cell A</td>
<td>Cell B</td>
<td>Cell C</td>
</tr>
</table>
| Cell A | Cell B | Cell C |
The cellpadding is 5
<table border="1" cellpadding="5">
<tr>
<td>Cell A</td>
<td>Cell B</td>
<td>Cell C</td>
</tr>
</table>
| Cell A | Cell B | Cell C |
The cellpadding is 15
<table border="1" cellpadding="15">
<tr>
<td>Cell A</td>
<td>Cell B</td>
<td>Cell C</td>
</tr>
</table>
| Cell A | Cell B | Cell C |