Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p><strong>Basics</strong></p> <p>For controlling "cellpadding" in CSS, you can simply use <code>padding</code> on table cells. E.g. for 10px of "cellpadding":</p> <pre class="lang-css prettyprint-override"><code>td { padding: 10px; } </code></pre> <p>For "cellspacing", you can apply the <code>border-spacing</code> CSS property to your table. E.g. for 10px of "cellspacing":</p> <pre class="lang-css prettyprint-override"><code>table { border-spacing: 10px; border-collapse: separate; } </code></pre> <p>This property will even allow separate horizontal and vertical spacing, something you couldn't do with old-school "cellspacing".</p> <p><strong>Issues in IE &lt;= 7</strong></p> <p>This will work in almost all popular browsers except for Internet&nbsp;Explorer up through Internet&nbsp;Explorer&nbsp;7, where you're almost out of luck. I say "almost" because these browsers still support the <code>border-collapse</code> property, which merges the borders of adjoining table cells. If you're trying to eliminate cellspacing (that is, <code>cellspacing="0"</code>) then <code>border-collapse:collapse</code> should have the same effect: no space between table cells. This support is buggy, though, as it does not override an existing <code>cellspacing</code> HTML attribute on the table element.</p> <p>In short: for non-Internet&nbsp;Explorer 5-7 browsers, <code>border-spacing</code> handles you. For Internet&nbsp;Explorer, if your situation is just right (you want 0 cellspacing and your table doesn't have it defined already), you can use <code>border-collapse:collapse</code>.</p> <pre class="lang-css prettyprint-override"><code>table { border-spacing: 0; border-collapse: collapse; } </code></pre> <p>Note: For a great overview of CSS properties that one can apply to tables and for which browsers, see this <a href="http://www.quirksmode.org/css/tables.html" rel="noreferrer">fantastic Quirksmode page</a>.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload