Writing HTML Code for Tables 1
Tables are used for holding data and organizing a page. They allow you to
separate a menu from contents of a page. They allow you to color and tile
images in select areas of a page.
A table consiists of rows and columns. Each row contains a set of cells.
Cells stacked up on one another represent a column.
This is a simple example of how a table is layed out. IT will look
like this:
|
cell 1 |
cell2 |
| cell 3 |
cell4 |
| Meaning of
tags. |
Tags |
| The Table Tag <TABLE> tells the
browser to start the table. |
<TABLE> |
| The table row tag <TR> tells the
browser that a new row is started. |
<TR> |
| The table data cell tag <TD>
tells the browser that there is a cell. The TD tag is the only place
that data can be put in a table. |
<TD> |
| The contents of the data cell is
placed between the start of the table data cell tag <TD> and the close
of it. </TD> |
cell 1 |
| The browser interprets this as
the close of the Table Data Cell |
</TD> |
| Start of a new cell |
<TD> |
| cell contents |
cell2 |
| Close of the data cell |
</TD> |
| The browser interprets the end
of the row tag </TR> as the end of that row in the table. |
</TR> |
| Start of a row |
<TR> |
| start of a data cell |
<TD> |
| cell contents |
cell 3 |
| end of a data cell |
</TD> |
| start of a data cell |
<TD> |
| cell contents |
cell 4 |
| end of a data cell |
</TD> |
| end of the table row |
</TR> |
| End of the table </TABLE> |
</TABLE> |
| |
|
Continue to TABLE WRITING 2