Question

I have a div and an iframe on the page the div has

z-index: 0;

the iframe has its content with a popup having a z-index of 1000

z-index: 1000;

However, the div still overshadows the popup in IE (but works fine in Firefox).

Does anyone know what I can do?

Was it helpful?

Solution

Explorer Z-index bug

In general, http://www.quirksmode.org/ is an excellent reference for this sort of thing.

OTHER TIPS

Which version of IE?

I'm no javascript guru, but I think hiding the div when the popup pops might accomplish what you need.

I've had to work with divs and iframes when creating a javascript menu that should show overtop dropdown boxes and listboxes -- other menu implementations just hide these items whose default behavior in IE6 is to show on top of any DIV, no matter the z-index.

I face the same problem. The problem in my case is that the content in the iframe is not controlled by IE directly, but by Acrobat as it is a pdf file. You can try to show the iframe without the content, in which case the popup displays normally. For some reason IE is not able to control the z-index for external helpers.

It was tested with IE7

Without seeing your code, it's difficult to determine the problem. But it's worth noting that z-index only works when the element has been positioned (e.g. position: absolute;), so perhaps that could be an issue?

There's a good article on CSS Z-index from the Mozilla Developer Center.

Without seeing a code snippet, it's hard to determine what the issue is. You may want to try appending an iframe under your popup that is the same size as your popup. With IE7 if you render the iframed popup after the other iframe has already loaded you should be able to cover up elements that are beneath. I believe some JS calendars and some lightbox/thickbox code does this if you are looking for examples.

never set your z-index to anything bellow 1 enless you want to hide it. I'm not sure about 7.0 but older versions of IE I've had issues with doing that. IE doesn't like z-index that much. Also check your positioning. Positioning may be your issue. sorry, i don't have enough info to help you further.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top