z-index css Pop-up box and ie7

爱⌒轻易说出口 提交于 2019-12-05 07:49:45

I think this is due to a z-index bug in Internet Explorer. Positioned elements (i.e. elements with a position other than static) establish their own stacking context.

http://www.quirksmode.org/bugreports/archives/2006/01/Explorer_z_index_bug.html

In my experience, it’s as if all your div.boardshot_list span.img_box have a z-index of 0, and elements inside each div.boardshot_list span.img_box have a z-indexes of 0.1, 0.2 and so on, instead of 1 and 2.

You should be able to fix the issue by setting the z-index of the span.img_box containing the visible pop-up to 1, like this:

// reset position of popup box
popup.css({
    top: -10,
    left: 20,
    display: 'block' // brings the popup back in to view
})

$(this).css('z-index', '1');

Don’t forget to reset it to 0 when the pop-up disappears.

Thevs

It's probably because of conflict of multiply classes (.container_speech_box and .popup) style resolution in different browsers. Try to wrap .popup div around the .container_speech_box.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!