• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 6. Tables > Spanning Multiple Rows or Columns

Spanning Multiple Rows or Columns

By default, a cell occupies or spans one row and one column. For most tables, this is sufficient. When you start to use tables for layout purposes, though, you'll encounter instances where you want a cell to span more than one row or column. HTML 4.0 supports attributes of the <TH> and <TD> tags that permit this effect.

Using the COLSPAN Attribute

The COLSPAN attribute inside of a <TH> or <TD> tag instructs the browser to make the cell defined by the tag take up more than one column. You set COLSPAN equal to the number of columns the cell is to occupy.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


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