Chapter 8 - Table Markup Flashcards
tabular material
data arranged into rows and columns
CSS Tables
nested divs provide the markup and CSS Table properties make them behave like rows and cells in the browser
<table>...</table>
tabular content (rows and columns)
<tr>...</tr>
table row
<th>...</th>
table header
<td>...</td>
table cell data
spanning
the stretching of a cell to cover several rows or columns, allowing you to create complex table structures
column spans
stretch a cell to the right to span over the subsequent columns
row spans
work like column spans, but they cause the cell to span downward over several rows
<caption>...</caption>
title or description to be displayed with the table
<thead>...</thead>
table header row group
<tbody>...</tbody>
table body row group
<tfoot>...</tfoot>
table footer row group
user agent
browser
<colgroup>...</colgroup>
a semantically related group of columns
<col></col>
…</col>
one column in a column group
What are the parts (elements) of a basic HTML table?
The table itself (table), rows (tr), header cells (th), data cells (td), and an optional caption (caption).
What elements can a table contain directly? (i.e., first-level children)?
The table element can directly contain tr, cpation, colgroup, thead, tbody, and tfoot elements.
What elements can a tr contain?
The tr element can contain only some number of th and td elements.
When would you use the col (column) element?
Use the col element if you wan tto include additional information about the structure of a table, to specify widths to speed up display, or to add certain style properties to a column of cells.