Re: Browser Differences With Table Attributes



On 2007-03-06, Rik <luiheidsgoeroe@xxxxxxxxxxx> wrote:
X l e c t r i c <Xlectric@xxxxxxxxx> wrote:

I did this page, to post at a webtv news group, to show what happens
when we do and do not specify values for table attributes.

http://www.xlectric.com/info/html/tabatt.html

When I viewed it on my PC I noticed that with some of the browsers there
is still some space at the bottom of the tables even when specifying
values of 0 (zero) for cellpadding and cellspacing.

I explain myself at the bottom of the page. Is there something that can
be done to eliminate that space, or is that simply the way it is ?

Hmmz, I'm not the one to explain in depth the reasons why, as I'm really
not qualified to do so, but this works in Opera:
td img{vertical-align:bottom;}

Floating the images would also work. It has something to do with how
inline images are placed on a line. Anyone with more to the point
knowledge care to elaborate?

Sounds like that's the one.

An <img> is inline and has vertical-align: baseline by default, so it
sits on the baseline, which means a gap underneath it for descenders in
the current font (tails of letters like g, y).

Firefox does a quirks-mode switch on this one. If you don't give it the
strict doctype, computed line height for a line containing only images
is the height of the highest image, which is aligned to the bottom of
the line box.

img {display: block;} is sometimes another solution.
.



Relevant Pages

  • Re: Multi-column layout with CSS
    ... necessarily wrong to specify a box in pixels. ... This is where the judgement comes in. ... has the bandwidth needed to resize the images without a perceptible ...
    (alt.html)
  • Re: Technique - how is this done?
    ... the images are divided in to groups of four on the bottom ... click on the top right picture (elephant closeup) ... i can not figure out how the planes of focus work in these images ... tilting the film plane or something like that but i can't find a list ...
    (rec.photo.digital.slr-systems)
  • Re: Command line options: using an [option: parameter] without a parameter passed to it
    ... >>> switches with optional arguments. ... that must rely on the existence of a hash key is always slightly obscure. ... as you care to specify. ... "Reply" at the bottom of the article headers. ...
    (comp.lang.perl.misc)
  • Re: URL displayed at bottom of browser
    ... | large images and thumbnail images that are displayed on my main web site. ... | the location of the larger image is displayed on the bottom of the browser. ... | at the bottom of the browser window to something of my own choosing? ...
    (microsoft.public.frontpage.programming)
  • Re: The lower class and their cars.
    ... gone to having more images and have left ... Medium priority ... Minify JavaScript ... Specify a Vary: Accept-Encoding header ...
    (comp.sys.mac.advocacy)