Below is a div set to: overflow: auto; it contains 5 floated li elements. Since the div has no height set, the browser should calculate the height based on its content and should include any floated elements in this calculation, so that they will be contained by the div. See the css 2 spec as to why this should work. And it does work, in Fire fox and web core browsers, according to Ann’s web site below it can be made to work for ie as well.
This has now been fixed in Opera 8.
See also Super simple clearing floats at Anne’s Weblog for an explanation of why this is useful and where I got the idea to try this approach from. His demonstrations doesn’t work on Opera ether
Back to my browser bugs page