Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

HTML colgroup width attribute

HTML width attribute

HTML colgroup Tag Reference HTML Tag

Example

An element with a predefined width of 200 pixels specified for the first column:

 

 

   

   

 

 

   

   

 

 

   

   

 

Month Savings
January $100
February $80

Try it »


Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the width attribute. However, no browser supports relative_length values.


Definition and Usage

In HTML5, the width attribute is not supported.

The width attribute specifies the width of the column group.

Normally, the space occupied by a column group is the space needed to display its content. The width attribute is used to set a predefined width for the column group.

**Note:** This attribute is overridden by any width setting in the element.


Syntax

HTML tag