This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Stylesheets > May 2005 > float problem in Gecko browsers





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author float problem in Gecko browsers
Kyle Matthews

2005-05-15, 4:18 am

Hello all,

I am currently working on a 2 column layout in which the smaller column
is fixed at 100px, and the larger column takes up the remaining space.
In Gecko browsers (Firefox, Netscape, Mozilla) sometimes the smaller
columns juts out to the right of the container 1px, and sometimes
doesn't reach the end by 1px. You can observe the phenomenon at
http:/www.digitalovertone.com/examples/floatprob.php. All the CSS is in
the header. Observe how the problem disappears or reverses as you
resize the window. This doesn't happen in IE, Opera, or Safari, but
does appear to occur on Gecko browsers on Windows and Mac.

Any thoughts on how to correct this?

Many thanks,

Kyle
Spartanicus

2005-05-15, 7:26 am

Kyle Matthews <pathetiqu@hotmail.com> wrote:

>http:/www.digitalovertone.com/examples/floatprob.php.


Putting up invalid code forces us to first correct your errors to see if
there's a relation to the problem, do this yourself *before* asking for
help:

http://validator.w3.org/check?uri=h...s/floatprob.php

--
Spartanicus
Kyle Matthews

2005-05-16, 4:21 am

Spartanicus wrote:
> Putting up invalid code forces us to first correct your errors to see if
> there's a relation to the problem, do this yourself *before* asking for
> help:


Right you are. The closing </html> tag has been added (I know it's a
matter of principle, but was it even a *possibility* that this was the
problem?). Apologies for forcing you to correct my errors. You will
hopefully forgive a frustrated user for copy-and-pasting a little
hastily. Or perhaps you won't - I had forgotten how deliciously
aggressive Usenet can be.

All is correct and valid now, but the problem still exists. I ended up
taking the layout I was working on in a different direction, but I am
still interested in this effect if anyone knows anything. It's possible
it has nothing to do with CSS at all and is simply a browser quirk.

Kyle
Spartanicus

2005-05-16, 7:20 am

Kyle Matthews <pathetiqu@hotmail.com> wrote:

>
>Right you are. The closing </html> tag has been added (I know it's a
>matter of principle, but was it even a *possibility* that this was the
>problem?).


Unlikely, but it prevented us from checking your css for errors (the w3c
css checker refuses to run on invalid xhtml).

>All is correct and valid now, but the problem still exists. I ended up
>taking the layout I was working on in a different direction, but I am
>still interested in this effect if anyone knows anything. It's possible
>it has nothing to do with CSS at all and is simply a browser quirk.


It's a Gecko quirk triggered by the reduced width of "container" the
nested float and the "margin:0 auto" set on "container".

Next time reduce an issue down to the minimum, this helps you to see
what's going on, you won't waste other people's time when you ask for
help, and it helps when submitting it as a bug.

You can submit this:
http://homepage.ntlworld.com/sparta...kofloatprob.htm
as a bug @ Mozilla. (copy to your own web space first)

--
Spartanicus
Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews