Normando Marcolongo

Navigation

Skip navigation.

Search

Site navigation

Email conversation

FromNormando Marcolongo
ToMe
SubjectStrange behaviour of a table and other
Date17 October 2004 22:48
AttachmentExisting page that he is using
Hi!

I know that your time is precious, but I'll try to ask some advice.

Go to that page: http://xxx.xxxxxxxxxxx.xx/xxxxxxxx/

If the look is perfect: that is the problem. With other _computers_ is not.
Yes, if you look at the page with: IE4 5.5 6 Mozilla/Firefox the site 
ooks about the same, but on some computer it has problems with the 
tables which compose the button just down the main logo and the 
'folder-style' body. The corners, in fact, are often not correctly aligned.

I don't know why I have to specify the backgroung-align property for the 
variable size portions of the buttons and of the body. The height 
property of the tables do not suffice?

The code validates and it seems to me very well written :-)
I'm not a professional and the site is for a friend who asked for help: 
he is a graphic designer (Photoshop/Indesign: no HTML).

Please, if you have some time, give me your advice!

Many thanks.
Normando
FromMe
ToNormando Marcolongo
SubjectRe: Strange behaviour of a table and other
Date18 October 2004 8:33
Normando,

I am not entirely sure, but I think I know what your problem is.

I think this is the old image-in-a-table bug. According to the standard,
images inside a table are just like images anywhere else.

The image should appear on top of the line of the text (in line with the
bottom of the letters abcdehiklmnorstuvwxz). However, when they are the
only thing in a table cell most people expect them to be put at the bottom
of the text (in line with the bottom of the letters gjpqy). However, that
should not actually happen, since the images are still inline elements.

In order to make more pages work properly, most browsers have an 'almost
standards compliant' rendering mode, where they will automatically make
images fill the whole table cell if they are the only thing in it, and the
document type is not strict. Although this is not correct, most browsers do
it anyway. However, some browsers do offer options to force correct
rendering under certain circumstances, and I think this is your problem.

If this is the cause of your problems, you should be able to make _all_
browsers display it correctly by making all of these special images use the
display:block; style. If an image is the only thing in a table cell, give
it this class:
<td><img class="onlyone" ...></td>
Then define that class in your stylesheet:
img.onlyone { display: block; }


Hope this helps

Mark 'Tarquin' Wilton-Jones - author of http://www.howtocreate.co.uk/
This site was created by Mark "Tarquin" Wilton-Jones.
Don't click this link unless you want to be banned from our site.