Position: absolute a div over Flash

2019-07-07 00:13发布

Is it possible to position: absolute a <div /> over a Flash banner without adding wmode="transparent" to the banner?

I have a lightbox that needs to appear above my ads but I can't directly modify the banners as they come from a third party.

Edit: The problem mainly occurs in IE where the Flash banner is shown above the lightbox.

5条回答
劳资没心,怎么记你
2楼-- · 2019-07-07 00:43

set the wmode="transparent" attrobute using javascript ??

Jquery

$(document).ready(function() {  
    $('.flash_container embed').attr('wmode', 'transparent');  
});
查看更多
放我归山
3楼-- · 2019-07-07 00:54

try

wmode="opaque"
i think this will allow html div to be displayed over flash. It works for me many times but it behaves differently in different browsers.

查看更多
smile是对你的礼貌
4楼-- · 2019-07-07 00:58

I haven't tested this, but you could try the iFrame hack you would apply for IE to show an absolute div over a select element. It consists of dynamically (or even hard-coded, why not) creating an iFrame container that you position above the Flash (in your case) with the lightbox content inside it.

Someone correct me if they tested and does not apply here, but even if it does, I wouldn't recommend it unless it's a life or death situation.

查看更多
地球回转人心会变
5楼-- · 2019-07-07 01:01

No it's not but you can just hide the banners when the lightbox is active.

查看更多
时光不老,我们不散
6楼-- · 2019-07-07 01:07

I am afraid no, if this was the case, we wold not have resorted to wmode="transparent", but i hope there is a way around it.

查看更多
登录 后发表回答