![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
![]()
![]() |
All tables start with the same information.
In most cases however one cell tables is not what people are looking for. So in this case I have shown some examples below on how you can alter your table to fit your needs and design preferences.
Abvoe is a two cell table. This is actually closer to what more people use, only with multiple rows. The code for this table would look like: <table border="1" >
Above is a two row table. This is another common table that allows various rows. This is usually combined with multiple columns as well. The code for this table would look like: <Table>
The code above is for a three cell table. The table takes up two rows in the first column creating one column, and the second column uses both rows. Please note the rowspan="2". This tells the first column to take up two rows, and allows the first cell to be larger than the other two. <table border="1" ><tr> <td rowspan="2">Purple =</td> <td >Red</td> </tr> <tr> <td>Blue</td> </tr> </table>
The example above is for a 4 row 3 column table. The title, in this case, takes up all three columns and is noted with the colspan="3". The colspan tells the table that the cell in question should span three columns. This allows the title to be centered over the items listed in the table.
In all of the examples it is important to remember how much space you would like
a cell to take up. This will become important when you need to figure out
how many rows or columns you need a specific cell to take up.
![]() ![]() ![]() ![]()
|
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||