CSS empty-cells Property


Example

Display no borders on empty cells in a table:

table {
  empty-cells: hide;
}
Try it Yourself »

Definition and Usage

The empty-cells property sets whether or not to display borders on empty cells in a table.

Note: This property has no effect if border-collapse is "collapse".

Show demo ❯

Default value: show
Inherited: yes
Animatable: no. Read about animatable
Version: CSS2
JavaScript syntax: object.style.emptyCells="hide" Try it

Browser Support

The numbers in the table specify the first browser version that fully supports the property.

Property
empty-cells 1.0 8.0 1.0 1.2 4.0


CSS Syntax

empty-cells: show|hide|initial|inherit;

Property Values

Value Description Demo
show Display borders on empty cells. This is default Demo ❯
hide Hide borders on empty cells Demo ❯
initial Sets this property to its default value. Read about initial
inherit Inherits this property from its parent element. Read about inherit

Related Pages

CSS tutorial: CSS Table

HTML DOM reference: emptyCells property


Copyright 1999-2023 by Refsnes Data. All Rights Reserved.