Set Cellpadding And Cellspacing In CSS

For More Videos Visit Our YouTube Channel




Here we consider how to Set Cellpadding And Cellspacing In CSS. Lets start with following example.

Set Cellpadding And Cellspacing In CSS, Cellpadding And Cellspacing In CSS, Cellpadding And Cellspacing Using CSS, Cellpadding In CSS, Cellspacing Using CSS, How To Set Cellpadding And Cellspacing In CSS, How To Set Cellspacing In CSS, How To Set Cellpadding In CSS, CSS

If we render the above table on the browser, the result is as shown below.

Set Cellpadding And Cellspacing In CSS, Cellpadding And Cellspacing In CSS, Cellpadding And Cellspacing Using CSS, Cellpadding In CSS, Cellspacing Using CSS, How To Set Cellpadding And Cellspacing In CSS, How To Set Cellspacing In CSS, How To Set Cellpadding In CSS, CSS

For providing the Cellpadding And Cellspacing, we can apply following style. The style needs to be applied for the table and td.

table
{
        border-spacing: 15px;
}
td
{
        padding: 10px;
        background-color: red;
}



CellSpacing can be done by using border-spacing for table. CellPadding can be done by using padding for td. The result is as shown below.

Set Cellpadding And Cellspacing In CSS, Cellpadding And Cellspacing In CSS, Cellpadding And Cellspacing Using CSS, Cellpadding In CSS, Cellspacing Using CSS, How To Set Cellpadding And Cellspacing In CSS, How To Set Cellspacing In CSS, How To Set Cellpadding In CSS, CSS