Help:Wiki University Wikitext--Tables - Captions

Table captions
So far we have learned how determine the width of our table and the type of border it will have, but we don't know what the table is about. It needs a title or a wikitext caption.

Caption tag
The tag is a pipe and a plus sign: |+
 * It does not need a |- before it.
 * It does not have a closing tag either.

Lets call our table "Heathy Foods"
 * We will use the table with a width of 100% and the columns set at 25%.
 * Here's how the table will look with a caption:

Here's the coding:
 * AGAIN NOTICE we are determining the width of the columns not just the width of the top row of cells.
 * NOTICE the width attribute is separated by a colon.

 Exercises
 * With our above table place a green border, "inset" style and 25 pixels wide.
 * Made the table 90% in width.
 * Next place a border around the cells in the first column.
 * Make the first column 35 percent width, the second 15%, the third 25% and let the last column determine its own width.

Check your answers >

 Quick Quiz
 * Putting the width in the first cell of a row determines the width of the first column in the table
 * A. True
 * B. False


 * The width of a table will be determined by the material in the cells, if you do not set the widths
 * A. True
 * B. False


 * You can set the width of a table in percentages only
 * A. True
 * B. False

Check your answers >