Table cell spacing in CSS
Document Sample


Table cell spacing in CSS
Written by mostup
Thursday, 03 September 2009 12:16 - Last Updated Thursday, 03 September 2009 13:28
Often times we might run into situations where we want to use cellspacing for each cell within a
table in CSS. However, this cannot be done using margins in TD.
1 2 3 4 5 6 7 8 < table cellspacing =
tbody
tr
td
td
td
td
tr
tr
td
td
td
td
tr
tbody
table
Result:
1.1 1.2
2.1 2.2
1/2
Table cell spacing in CSS
Written by mostup
Thursday, 03 September 2009 12:16 - Last Updated Thursday, 03 September 2009 13:28
A compatible CSS version to cell spacing is as following:
1 2 3 4 5 6 7 8 <table style = "border-spacing:10px;b
Result: 1.1 1.2
2.1 2.2
the key is to set border-spacing and "border-collapse" to separate.
2/2
Get documents about "