session 9-TABLE ATTRIBUTES
Let's create a table with two rows, each with two cells in them (4 cells in total). Note how the <tr> and <td> tags are positioned:Since we want two rows, there are two <tr> tags present. Since we want to cells in each of the rows, there are two <td> tags present in each <tr>. ........Table Attributes - Tables accept various attributes that control how a table is to look. Some of the basic table attributes:
<table><tr><td>Cell #1</td><td>Cell #2</td><tr><td>Cell #3</td><td>Cell #4</td></tr></table>
Cell #1
Cell #2
Cell #3
Cell #4
attributes
Function
border=?
Specifies the border width of the table, in pixels.
width=?
Specifies the width of the table or cell, in pixels or %.
height=?
Specifies the height of the. table or cell, in pixels or %
cellpadding=?
Specifies the distant between the cell and the content inside.
cellspacing=?
Specifies the spacing between each cells, in pixels.
Here's an example that uses some of the above attributes:
<table border=3 width=200 cellpadding=20><tr><td>Cell #1</td><tr><td>Cell #2</td></tr></table>
Cell #1
Cell #2
Music News Health History Sports Archaeology Geography College Courses