Tables
This tutorial will show you how to make tables, which are boxes that are used to display content.
Start off your table code with the basic table tag. This is a table with 1 column and 1 row.
<table> <tr> <td>TEXT HERE</td> </tr> </table>
The tr tag adds a new row. The td tag adds a new cell (box) in that row. So if you want to add another cell to that row, you would use this code:
<table> <tr> <td>TEXT HERE</td> <td>TEXT HERE</td> </tr> </table>
To add another row, use this code:
<table> <tr> <td>TEXT HERE</td> <td>TEXT HERE</td> </tr> <tr> <td>TEXT HERE</td> <td>TEXT HERE</td> </tr> </table>
To customize your tables, add these right after the first table tag.
- border="BORDER WIDTH"
- bgcolor="#HEX CODE"
- colspan=NUMBER (this makes a row take up all of the cells in that row)
- cellspacing="NUMBER" (this adds spacing between the cells)
- cellpadding="NUMBER" (this adds padding inside the cells)
- width="NUMBER"
- style="background:url(yourfilename.gif)" (adds a background image)
Need more help with a tutorial?
Contact me.
Contact me.
