• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Table Elements

The first step in becoming aware of how best to use tables as a fundamental tool in Web design is to understand the HTML and XHTML elements used to create them (see Table 9.1).

Table 9.1. Table Elements in HTML and XHTML
ElementPurpose
tableThe main table tag, it denotes the beginning and subsequent end of a table.
trThe table row tag and its companion closing tag, <tr></tr>.
tdThe table data or table cell. This tag is used to define individual table cells.
thDefines a cell with header information. Typically, this renders in bold.
captionA caption describes the nature of a table. You are allowed only one caption per table. Captions are especially helpful for accessibility and are rarely used in table layout, but rather are reserved for table data.
theadTable head, for table header information.
tfootTable foot, for footer information.
tbodyTable body.
colgroupDefines a group of columns. There are two ways to specify the group. One is to use the span attribute to specify the number of columns to be grouped. The other way is to use the col element.
colUsed to define columns within a group.



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint