CSS table-layoutProperty


Example

Set the layout algorithm of the table:

table
{
table-layout:fixed;
}

Try it Yourself »

Property definition and usage instructions

The table-layout property sets the table layout algorithm for a table.

Default value: auto
Inherited: no
version: CSS2
JavaScript Syntax: object.style.tableLayout="fixed"


Browser Support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the table-layout property.

Note:IE7 and earlier versions do not support the "inherit" value. IE8 requires defining !DOCTYPE. IE9 supports "inherit".


Property value

Value Description
automatic Default. Column widths are set by cell content.
fixed The column width is determined by the table width and the column width setting.
inherit Specifies that the value of the table-layout property should be inherited from the parent element.


Related Articles

CSS Tutorial:CSS Tables

other extensions