0 votes
99 views
in HTML by (3.5k points)
edited

 How is Cell Padding different from Cell Spacing?

1 Answer

0 votes
by (3.5k points)
selected by
 
Best answer

Cell Padding and Cell Spacing are the attributes of formatting a table basically sets the white spaces in your table.

Cell Padding Cell Spacing
Used to fix the width/space between the border and its content Fixes the white space between the single cell, i.e., space between the edges and adjacent cell
Syntax:
<table cellpadding=”value” >
…..
…..
</table>
Here, cellpadding value specifies the space between the border and its content
Syntax:
<table cellspacing=”value” >
…..
……
</table>
Here, cellspacing value specifies the space between adjacent cells
The default cellpadding value is 1 The default cell spacing value is 2

Related questions

0 votes
1 answer 102 views
asked Aug 21, 2022 in HTML by codelikepro (3.5k points)
0 votes
1 answer 101 views
0 votes
1 answer 117 views
0 votes
0 answers 92 views

Doubtly is an online community for engineering students, offering:

  • Free viva questions PDFs
  • Previous year question papers (PYQs)
  • Academic doubt solutions
  • Expert-guided solutions

Get the pro version for free by logging in!

5.7k questions

5.1k answers

108 comments

561 users

...