You are here: Re: layer order z-index not working: help!! « HTML « IT news, forums, messages
Re: layer order z-index not working: help!!

Posted by Susanne West on 02/22/07 11:10

to put it simple: you're THE MAN! (*bow,bow,bow*)

thanks!!!! works beautifully! even in IE (believe it
or not).

i finally did keep the z-index in there just for the
sake of the ordering...

the reason for the nested divs was a previous layout
version with only one 'popup'. in that case the problem
was not obvious since no 'overlap' with another box
occured. but i'd still say the way you proposed is
the best.







Ben C wrote:
> On 2007-02-20, Susanne West <swest@gmx.de> wrote:
>
>>
>>hi.
>>
>>i have this case, where (for about 2 days now) i'm trying to
>>get z-index to work correctly and i can't figure out what's wrong.
>>
>>IE seems to completely ignore it, while firefox does it
>>properly... it's basically just a series of pulldowns done
>>with div's...
>
>
> I don't have IE but I had a look at it anyway because I thought it's
> quite likely you don't need z-index at all, and without it maybe you
> could avoid the problem.
>
> Without z-index the page works as you want in Opera, but not in Firefox.
>
> I think Opera is correct on this one. A bit of experimentation revealed
> that the thing that's confusing Firefox is that the boxes after the one
> that you toggle on and off are also in the relatively positioned box.
>
> To recap, you have this:
>
> <rel pos box>
> <abs pos box, display: none></abs pos box>
> <another box>...</another box>
> </rel pos box>
>
> When you switch the abs pos box to display:block, the inline boxes in
> <another box> get drawn on top of it (although <another box>'s
> background is behind it). There is no justification for this if I
> understand the CSS 2.1 spec correctly.
>
> But this works:
>
> <rel pos box>
> <abs pos box, display: none></abs pos box>
> </rel pos box>
> <another box>...</another box>
>
> Positioning is the same, but FF gets the stacking right and you don't
> need to use z-index. You will have to try it in IE, where all bets are
> off but you never know.
>
> I have uploaded the modified page, without z-index and closing the rel
> pos boxes earlier, since people prefer urls. I also gave it a strict
> doctype (very important, not using the strict doctype leads to
> insanity).
>
> http://www.tidraso.co.uk/misc/pulldowns.html

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация