Opening Tag | Content | Closing Tag | ||||
---|---|---|---|---|---|---|
Open | Parameter | = | Value | Close | ||
<table | border | > | caption and/or table rows |
</table> | ||
bgcolor | = | color | ||||
background | = | file | ||||
border | = | pixels | ||||
cellpadding | ||||||
cellspacing | ||||||
width | = | pixels | ||||
percent% | ||||||
height | = | pixels | ||||
percent% |
Opening Tag | Content | Closing Tag | ||||
---|---|---|---|---|---|---|
Open | Parameter | = | Value | Close | ||
<caption | align NC | = | top NC | > | caption text |
</caption> |
bottom NC | ||||||
align IE | = | left IE | ||||
center IE | ||||||
right IE | ||||||
valign IE | = | top IE | ||||
bottom IE |
Opening Tag | Content | Closing Tag | ||||
---|---|---|---|---|---|---|
Open | Parameter | = | Value | Close | ||
<tr | valign | = | top | > | table headers and/or table rows |
</tr> |
middle | ||||||
bottom | ||||||
align | = | left | ||||
center | ||||||
right | ||||||
bgcolor | = | color | ||||
background | = | file |
Opening Tag | Content | Closing Tag | ||||
---|---|---|---|---|---|---|
Open | Parameter | = | Value | Close | ||
<th or <td |
valign | = | top | > | table cell data |
</th> or </td> |
middle | ||||||
bottom | ||||||
align | = | left | ||||
center | ||||||
right | ||||||
width | = | pixels | ||||
percent% | ||||||
height | = | pixels | ||||
percent% | ||||||
colspan | = | columns | ||||
rowspan | = | rows | ||||
nowrap | ||||||
bgcolor | = | color | ||||
background | = | file |
When spanning rows, subsequent rows have fewer explicitly-defined table-data cells than you might expect: the unspecified cells are filled with content from a previous row's row-spanning table cell (see example below).
Table headers/cells that do not contain anything, do not even appear as a cell; there is simply a "dentless" area (table cells appear to be "dented" into the page). If you want a table cell to be dented in, but still have no visible content, put a linebreak (<br>) or a non-breaking space ( ) in the cell.
This is Column One |
The Rest of the Columns | |||||||
---|---|---|---|---|---|---|---|---|
Column Two | Column Three | Column Four | Column Five | |||||
Observe the | different | horizontal | alignment! | |||||
This here is a really tall chunk of data. |
Note the | different | vertical | alignment. | ||||
The alignment for this whole row |
was set | in one swell foop |
in the | <tr> tag. | ||||
As you can see, you can
span columns or |
|
This is the Caption to the Sample Table This is
Column OneThe Rest of the Columns Column Two Column Three Column Four Column Five Observe the different horizontal alignment! This here
is a really
tall chunk
of data.Note the different vertical alignment. The
alignment
for this
whole rowwas set in one
swell foopin the <tr> tag. As you can see, you can span columns or rows. . .
Nested Table This is a nested Table!