> On Tue, Nov 17, 2009 at 10:56 PM, Mark Henderson <[email protected]> wrote:
> 
>> Alan Gresley wrote on 18 November 2009 at 16:45
>> [..]
>>> I have no specific test case for IE7- but is this your bug.
>>>
>>>
>> <http://css-class.com/test/bugs/gecko/1-7~1-9/floats-inline-and-float.ht
>> m>
>> Ah ha! Well that does seem to fit with his earlier code snippet, good
>> spotting.
>>
>>> BTW, please specify which IE version you have the problems in future.
[...]
>> Alan, it's in the subject line!

Yes it is Mark, didn't look there.

jeffrey morin wrote:

> Thanks for all the help here. Alan, I think you have basically found the
> issue. It seems to be solved in later Gecko versions so that is why I
> haven't had the issue anywhere besides *IE7. *(haven't checked in 6 since we
> aren't supporting it, thankfully)


The linked test case is a old Gecko bug with inline elements among 
floats (This is still present in the latest Gecko). I just linked to 
that test case since the IE7- expansion bug is seen in it. I have now 
completed a proper test case for the IE7-bug.

<http://css-class.com/test/bugs/ie/float-auto-width-expansion-bug.htm>


> So since I don't have my own domain as of yet and our test servers are
> password protected I have done this. I have taken two screenshots of what
> should happen and what IE7 does. Those are here.
> 
> http://rufus2021.wordpress.com/2009/11/18/ie7-float-issue/
> 
> The exact code for this is as follows: Slight correction from before, one of
> the elements is actually an <a> tag but it doesn't seem to make a difference
> whether they are inputs or links. Same result.
> 
> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
>    "http://www.w3.org/TR/html4/loose.dtd";>
> 
> <html lang="en">
> <head>
> <style>
> div { border: 1px solid red; float: right; }
> input { border: 1px solid green; float: left; }
> a { border: 1px solid blue; display: block; float: right; }
> </style>
> </head>
> <body>
> 
> <div>
> <input type="text" value="floating left" />
> <a href="#">floating left</a>
> </div>
> </body>
> </html>
> 
> 
> It looks like it's just a case of there needing a width set to help IE
> along. Does anyone know if there is any documentation on this anywhere else?

A width or the method you suggest below. To my knowledge, there is no 
documentation. I spotted the bug around a year ago and mentioned in on 
this list. This is just one of 100s of IE7- non standard float model bugs.


> IE7 will give me the correct display, which Safari and later Gecko browsers
> give, if i float both of the elements inside of the div left and still have
> the div floating right. It is as if IE7 just let's the div run wild if the
> child elements are floating in opposite directions.
> 
> - Jeff


The bug is not present if there are only floated left children so this 
will be a reasonable workaround.

IE7 is very wild and is much like IE6 but with the screws tighten up to 
hold it mostly together. The origins for many of these bugs are due to 
the non standard float model (float is a hasLayout trigger) or elements 
with hasLayout or lack of hasLayout. The problems with hasLayout are 
well documented here.

<http://www.satzansatz.de/cssd/onhavinglayout.html>


-- 
Alan http://css-class.com/

Armies Cannot Stop An Idea Whose Time Has Come. - Victor Hugo
______________________________________________________________________
css-discuss [[email protected]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to