Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Getting rid of table padding using css

Status
Not open for further replies.

joelwenzel

Programmer
Jun 28, 2002
448
I'm having a problem removing the padding from a table in Internet Explorer. In netscape, there is no space between the span and the border or the table but in IE there is a space of about 1px between the border and the span.

<style type=&quot;text/css&quot;>
TD{
margin:0px;
padding:0px;
}
SPAN{
margin:0px;
padding:0px;
border:1px solid black;
}
</style>

...

<table cellpadding=0 cellspacing=0 border=1>
<tr><td>
<span>stuff</span>
</td></tr>
</table>
 
There is a space of about 1px between the top border pf the span tag and the table. The side and bottom borders of the span are right on the border of the table.
 
I've change some things and have learned that the problem comes when I set the font-size less than 12pt. Anyone know a work around?
 
Hi,

Just a thought, have you tried something different to useing PX, like other units?

James
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top