This page is Ready to Use

Notice: The WebPlatform project, supported by various stewards between 2012 and 2015, has been discontinued. This site is now available on github.

empty-cells

Summary

Sets whether or not to display borders and background on empty cells in a table.

Overview table

Initial value
show
Applies to
table-cell elements
Inherited
Yes
Media
visual
Computed value
Same as specified
Animatable
No
CSS Object Model Property
emptyCells

Syntax

  • empty-cells: hide
  • empty-cells: show

Values

show
Renders empty cells with inherited borders and styles
hide
Does not render the cell

Examples

/*
  * This example hides any table cell that has no data in it
  */

td{
    empty-cells: hide;
}

View live example

Notes

Remarks

If all cells in a particular row have the empty-cells value set to hide, the entire row will behave as if it had the display value of none. The empty-cells value can be set for an entire table. If the value is set in the table properties to show,all cells will be rendered with borders, regardless of their content.

Syntax

empty-cells: show | hide

Standards information

See also

Related articles

Tables

Related pages

Attributions