Create tables with different border width
Description:
How to create tables with different border width.
Code:
<html>
<body>
<h4>Normal border</h4>
<table border="1">
<tr>
<td>cell 1</td>
<td>cell 2</td>
</tr>
<tr>
<td>cell 3</td>
<td>cell 4</td>
</tr>
</table>
<h4>Thick border</h4>
<table border="5">
<tr>
<td>cell 1</td>
<td>cell 2</td>
</tr>
<tr>
<td>cell 3</td>
<td>cell 4</td>
</tr>
</table>
<h4>Very thick border</h4>
<table border="10">
<tr>
<td>cell 1</td>
<td>cell 2</td>
</tr>
<tr>
<td>cell 3</td>
<td>cell 4</td>
</tr>
</table>
<h4>Very, very thick border</h4>
<table border="20">
<tr>
<td>cell 1</td>
<td>cell 2</td>
</tr>
<tr>
<td>cell 3</td>
<td>cell 4</td>
</tr>
</table>
</body>
</html>
Play with the code:
See working example:
Explanation:
To create tables with different border in an html page, you just have to give different value at the attribute border.
See Also:
HTML: Html, Body, Table, Tr, Td
|