CSS empty-cellsProperty


Example

Hide borders and background of empty cells in a table:

table
{
border-collapse:separate;
empty-cells:hide;
}

Try it Yourself »

Attribute definition and usage instructions

The empty-cells property sets whether to display empty cells in a table (only used in the "separated borders" mode).

Default value: show
Inherited: yes
version: CSS2
JavaScript Syntax: object.style.emptyCells="hide"


Browser Support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the empty-cells property.

Note:Only when a !DOCTYPE is specified does IE8 support the empty-cells property.


Property value

Value Description
hide Do not draw borders around empty cells.
show Draw borders around empty cells. Default.
inherit Specifies that the value of the empty-cells property should be inherited from the parent element.


Related Articles

CSS Tutorial:CSS Table

other extensions