Add space between cells (td) using css

Mine is:

border-spacing: 10px;
border-collapse: separate;

Consider using cellspacing and cellpadding attributes for table tag or border-spacing css property.


table { 
  border-spacing: 10px; 
} 

This worked for me once I removed

border-collapse: separate;

from my table tag.


You want border-spacing:

<table style="border-spacing: 10px;">

Or in a CSS block somewhere:

table {
  border-spacing: 10px;
}

See quirksmode on border-spacing. Be aware that border-spacing does not work on IE7 and below.

Tags:

Html

Css