|
Posted by Jonathan N. Little on 11/21/07 17:21
richard wrote:
> On Wed, 21 Nov 2007 00:36:48 -0800 (PST), jodleren wrote:
>
>> hi all!
>>
>> I have this
>>
>> <table cellpadding=0 cellspacing=0 border=0>
>> <tr><td valign="top">
>> <img src="img1.gif" border=0>
>> </td><td valign="top">
>> a
>> </td></tr>
>> <tr><td valign="top">
>> <img src="img2.gif" border=0><img src="img3.gif" border=0>
>> </td><td valign="top">
>> b
>> </td></tr></table>
>>
>> Problem: IE gives a small pixel distance between the rows. Firefox
>> does not.
>> I have another file, which works in IE. But I cannot tell the
>> difference, except it consists of 3 td's, and their width's are set.
>>
>> What is the secret?
>
> In css, use margin:0
> I believe IE uses a default of 1.
Applied to what? Images, no. Images are inline by default so margins are
no applicable. I would think the problem would be more likely to happen
in Firefox not IE because improperly does not incorporate glyph ascender
and descender dimensions when determining line-height so since images
are inline Firefox added this space and hence the space above and below
images. You can add "display: block" on your images but you will have to
deal with the two images side-by-side.
We really do not have enough info to help, need the actually URL to the
page.
> you should also use quotes around numbers.
> cellpadding="0".
> without quotes it may be overlooked as being faulty.
We again depends. Need URL to see. If HTML attribute values without
embedded spaces do no need to be quoted, but it is good practice to do so.
>
> Then why are you placing images inside a table anyway? They should be in a
> division which would make coding simpler.
>
> <div class="image1">image1.gif</div>
> use css to define the peramiters.
Agree. Most likely OP knows no other way.
--
Take care,
Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
Navigation:
[Reply to this message]
|