< Back to Coding, HTML

Styling tables with CSS

This is how you replicate cellspacing and cellpadding with CSS.

table.css {
    width:50%;
     display: table;
     border-collapse: separate;
     border-spacing: 20px;
     border:1px black solid;
}
.css td{
    border:1px green solid;
    padding:10px;
}

View the demo

Download the demo

Be Sociable, Share!

Leave a Reply

Your email address will not be published. Required fields are marked *