In this tutorial you will learn about the CSS Tables and its application with practical example.
CSS gives us better way to add styling to the HTML Tables, we can set various properties for HTML Table using CSS.
Table Of Contents−
We can set CSS using table, th, tr, and td as selectors.
Property | Description |
---|---|
empty-cells | This property specifies whether the border should be shown if a cell is empty for the HTML Table. |
border-collapse | This property specifies whether the adjacent borders that touch each other or each cell should keep borders separate for HTML Table. |
border-spacing | This property specifies horizontal and vertical cellspacing that separates adjacent cells for the HTML Table. |
table-layout | This property specifies lay out of the HTML Table. Example – fixed, auto or inherit. |
caption-side | This property specifies the placement of the caption for HTML Table. Example – top,bottom,left,right. |