Click to See Complete Forum and Search --> : Tables padding
spazin42o
11-21-2006, 02:41 AM
i am in the middle of designing a website and im using tables to create the layout with graphics i've created in a graphics program. I made the tables cellpadding set to = 0 but yet when i still put images into the table there is still a space on the bottom of it.
here is a screen shot of it to make what im trying to ask more easier to understand.
here (http://img224.imageshack.us/img224/8950/untitled2dod2.jpg)
i want to rid the gap between the 2 images and the bottom of the table.
NogDog
11-21-2006, 02:46 AM
Try adding this to the <head> section of your page:
<style type="text/css">
table img {
display: block;
}
</style>
spazin42o
11-21-2006, 02:54 AM
Try adding this to the <head> section of your page:
<style type="text/css">
table img {
display: block;
}
</style>
ehh it brought the image to meet the bottom border of the table but it messed it up also... now it looks like this...
here (http://img205.imageshack.us/img205/6670/untitled4ct9.jpg)
MikeFlyer
11-21-2006, 04:47 AM
Make Sure about the CellSpacing = 0
and the which indicates the white spaces between characters
but i think this is because of the cellspacing between the cells of the table
scrap all the table/cell/row spacing/padding, put in
<style type="text/css">
*{margin:0;padding:0;}
</style>
Remember images might have a default padding/margin too.
On a side not, you *really* should NOT be using tables to layout your pages!! We aren't living in the stone age anymore.
Why Tables for layout is stupid (http://www.hotdesign.com/seybold/)