Ingo Chao wrote: > Tribou, Eric wrote: > >> I ran across an odd IE7 bug and spent some time trying to figure it out. >> I thought I'd share and ask if anyone has seen or heard anything like >> this? >> >> Here's a demo page I put together for view in IE7: >> http://webhost.bridgew.edu/etribou/layouts/rmenu/bug.html >> >> CSS-based dropdown menus. The first menu is how things originally >> performed. No real problems. >> >> In the second menu I specifically set the background color of LI >> elements to a gray color. That's it (CSS is embedded, view source to >> check it out). Now the menus pop BEHIND LI elements that are not their >> parent. Just by setting a background color?! >> > > > Eric, > > the change in the stacking is pretty surprising. > > In IE7, the old IE hover (pure CSS pop-ups) bug [1, 2, etc.] was > developed further (see [3] for more threads and thoughtd on this, don't > know if someone took the time to demonstrate it). > > Add a "kick" to the hovered element itself: > > li:hover {background-position: 0 0;} > > > Regards, > > Ingo > > > [1] http://www.tanfa.co.uk/css/articles/pure-css-popups-bug.asp > [2] http://www.satzansatz.de/cssd/pseudocss.html#hoverdesc > [3] http://archivist.incutio.com/viewlist/css-discuss/81588 >
Yes, this is an example of a 'new' version of the old IE stacking bugs on backgrounds. I've seen it before: http://www.aplus.co.yu/css/ie7-bug-1-nested-list-abs-positioned-is-overrun-by-preceding-links-background-colour/ The answer as with so many things IE-bug related is to trigger 'layout' on the element with the background that's showing through, or on any other 'wrapping' element between the one with the background and the one that's disappearing. If you're only getting a bug in IE7 then you can use min-height or min-width set to 1px to achieve this, which is both valid and layout neutral so doesn't need any fiddling around with conditional comments or hacks/filters. -- Sophie Dennis, Creative Director Cayenne Web Development Limited www.cayenne.co.uk Bloxham Mill, Barford Road Bloxham, Oxfordshire OX15 4FF t. 0870 389 0570 m: 07814 026632 Reg. England and Wales no. 4502369 ______________________________________________________________________ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d IE7 information -- http://css-discuss.incutio.com/?page=IE7 List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/