如何获得一个元素来覆盖Flash视频(尝试wmode = transparent)? [英] How do I get an element to cover a Flash video (tried wmode=transparent)?

查看:189
本文介绍了如何获得一个元素来覆盖Flash视频(尝试wmode = transparent)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



由于某些原因,即使在添加<$ c $的时候, c>< param name =wmodevalue =transparent> 到Flash对象,它仍然覆盖HTML元素(高于 z-index 太)。



我已经在

我做错了什么?

谢谢

< h2> Update

奇怪的是,这种行为发生在Windows Firefox和IE8上。在Mac上的Firefox上,它呈现的很好。

您同时拥有嵌入和对象。您需要将wmode应用于嵌入。



http://jsfiddle.net/zCDVx/2/

 < object width =640height = 385 > 
< param name =movievalue =http://www.youtube.com/v/_-wDuGDtjCc?fs=1&amp;hl=en_GB>
< param name =wmodevalue =transparent>
< param name =allowscriptaccessvalue =always>
< / object>


I have a Youtube video on my homepage, and now I need a modal to display on certain events.

For some reason, even when adding <param name="wmode" value="transparent"> to the Flash object, it still covers the HTML elements (with higher z-index too).

I've got it on JSfiddle.

I figured maybe an iframe could solve this, but that would require me to make a new page just to put the video on.

Am I doing something wrong?

Thanks

Update

Strangely, this behaviour happens on Windows Firefox and IE8. On Firefox on Mac, it renders fine.

解决方案

You have both an embed and object. You need to apply the wmode to the embed.

http://jsfiddle.net/zCDVx/2/

<object width="640" height="385">
    <param name="movie" value="http://www.youtube.com/v/_-wDuGDtjCc?fs=1&amp;hl=en_GB">
    <param name="wmode" value="transparent">
    <param name="allowscriptaccess" value="always">
    <embed src="http://www.youtube.com/v/_-wDuGDtjCc?fs=1&amp;hl=en_GB" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="640" height="385" wmode="transparent"></embed>
</object>

这篇关于如何获得一个元素来覆盖Flash视频(尝试wmode = transparent)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆