May 05, 2021 CSS Reference Manual
Set up border-spacing for the table:
table
{
border-collapse:separate;
border-spacing:10px 50px;
}
Border-spacing properties are supported by all major browsers.
Note: If specified! DOCTYPE, then Internet Explorer 8 (and later) supports the border-spacing property.
The border-spacing property sets the distance between the borders of adjacent cells (only for Border Separation mode).
Note: Some versions of Internet Explorer do not support this property.
This property specifies the distance between cell boundaries in the separated border model. O f the two specified length values, the first is a horizontal interval and the second is a vertical interval. T his property is ignored unless border-collapse is set to part. Although this property applies only to tables, it can be inherited by all elements in the table.
Default: | not specified |
---|---|
Inheritance: | yes |
Version: | CSS2 |
JavaScript syntax: | object .style.borderSpacing="15px" |
Value | Describe |
---|---|
length length |
Specifies the distance between the borders of adjacent cells. U se px, cm, etc. Negative values are not allowed. If you define a length parameter, you define horizontal and vertical spacing. If two length parameters are defined, the first sets the horizontal spacing and the second sets the vertical spacing. |
inherit | Specifies that the value of the border-spacing property should be inherited from the parent element. |