Column Group | WebReference

Column Group

HTML 4.01 Element Reference

By Lee Underwood

Return to HTML 4.01 element index page

Name: Column Group

<colgroup> ... </colgroup> (opt.)

Description: Defines the characteristics for a group of columns in a table.

Browser Compatibility: IE: 4.0+

Attributes:
  • align
  • char
  • charoff
  • class
  • dir
  • id
  • lang
  • onclick
  • ondblclick
  • onkeydown
  • onkeypress
  • onkeyup
  • onmousedown
  • onmousemove
  • onmouseout
  • onmouseover
  • onmouseup
  • span
  • style
  • title
  • valign
  • width

Code Example:

<table width="450">
<colgroup valign="top">
<col align="left" width="50"><col>
</colgroup>
  <tr>
    <td>
This column is aligned to the left and at the top.</td>
    <td>
This column is centered and aligned at the top.</td>
  </tr>
</table>

XHTML Notes: The closing </colgroup> element is required.




Created: March 15, 2005

URL: http://webreference.com/html/reference/specs/