无法获取 Flash 文件上方的 CSS 下拉菜单

发布于 2024-08-11 06:49:56 字数 462 浏览 4 评论 0原文

我已经搜索了所有内容并尝试了所有我能掌握的方法,但无法让 CSS 下拉菜单显示在 Flash 文件上方。

您可以访问:http://beta.riverlifefellowship.com,用户名是“riverlife”,密码是“ flow'(两者都没有引号)。

我正在使用 swfObject 并设置了 。下拉菜单周围的 div 是绝对位置,z-index 为 9999,flash 文件周围的 div 是相对位置,z-index 为 -1

任何有关尝试的建议都非常感谢!

[注意:它适用于 Mac 操作系统上的所有浏览器,但不适用于 Windows 操作系统上的浏览器]

I have searched everything and tried every method I can get my hands on and cannot get my CSS drop-down menus to display above my Flash file.

You can go to: http://beta.riverlifefellowship.com and username is 'riverlife' and password is 'flow' (without the quotes on both).

I am using swfObject and have the <param name="flashvars" value="wmode=opaque"/> set. The div around the drop down is absolute position with z-index of 9999 and the div around the flash file is relative position with z-index of -1

Any suggestions of things to try is greatly appreciated!

[Note: It is working in all browsers on Mac OS but no browsers on Windows OS]

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

梓梦 2024-08-18 06:49:56

将 Flash 上的 wmode 属性设置为透明 - 通常可以

编辑:
您正在使用 嵌入 .swf - 这是一种方法,但 将适用于更多浏览器,并且实际上可以解决问题大部分,结合你已经设置的wmode。 Adobe Dreamweaver 有一种很好的方法来创建一些 JavaScript,用于根据浏览器处理 的选择。但如果没有它,你的代码基本上应该是这样的。 (这在 Firebug 中测试并有效)

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" 
    codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="980" height="250">
    <param name="movie" value="/files/themes/RiverLife-Oct09/media/header_ssp2.swf" />
    <param name="quality" value="high" />
    <param name="wmode" value="opaque" />
    <embed src="/files/themes/RiverLife-Oct09/media/header_ssp2.swf" quality="high" wmode="opaque" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="980" height="250"></embed>     
    </object>

Set the wmode property on the Flash to transparent - that usually works

EDIT:
You are using <object> to embed the .swf - which is one way, but <embed> will work across more browsers and will actually solve the problem for the most part, combined with the wmode you already have set. Adobe Dreamweaver has a nice way of creating some javascript that handles the choice of or <object> based on the browser. But without that your code should basically look like this. (This is tested in Firebug and worked)

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" 
    codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="980" height="250">
    <param name="movie" value="/files/themes/RiverLife-Oct09/media/header_ssp2.swf" />
    <param name="quality" value="high" />
    <param name="wmode" value="opaque" />
    <embed src="/files/themes/RiverLife-Oct09/media/header_ssp2.swf" quality="high" wmode="opaque" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="980" height="250"></embed>     
    </object>
御弟哥哥 2024-08-18 06:49:56

除非您确实需要透明度(即,您的Flash影片具有透明背景),否则最好的选择是使用opaque作为wmode,将会比 transparent 具有更好的性能。只有 wmode="window"(默认设置)会阻止浏览器在 Flash 上进行绘制。

http://www.communitymx.com/content/article.cfm?cid= e5141

这种模式让我感到困惑
由于这样的措辞:“不透明模式
让电影把一切都隐藏起来
它在页面上。另外,不透明
模式将元素移动到 Flash 后面
电影(例如,动态的
HTML)以防止它们显示
通过。”事实是,因为通过使用
wmode="opaque",您已经放置了
Flash Player直接拖到页面上,
它现在可以接受放置并
像任何其他元素一样定位。
除非您的观看者没有使用
兼容的浏览器(遵循列表),
z-index 将受到尊重并且
呈现。所以是的,你可以移动
Flash 影片背后的元素
防止它们显露出来,但是
您可以轻松地移动
Flash影片前面的元素
防止Flash显示
通过。

Unless you actually need the transparency (i.e., you flash movie has a transparent background), the best choice is to use opaque for the wmode which will have better performance than transparent. Only wmode="window" (which is the default) prevents the browser from drawing on top of the flash.

http://www.communitymx.com/content/article.cfm?cid=e5141

This mode is the one that confused me
due to this wording: "Opaque mode
makes the movie hide everything behind
it on the page. Additionally, opaque
mode moves elements behind Flash
movies (for example, with dynamic
HTML) to prevent them from showing
through." Truth is, since by using
wmode="opaque", you've placed the
Flash Player directly onto the page,
it can now accept placement and
positioning like any other element.
Unless your viewer is not using a
compliant browser (list to follow),
the z-index will be respected and
rendered. So yes, you can move
elements behind Flash movies to
prevent them from showing through, but
you can just as easily move the
elements in front of the Flash movies
to prevent the Flash from showing
through.

青柠芒果 2024-08-18 06:49:56

你把wmode设置成透明了吗?

<param name="wmode" value="transparent" />

Did you set the wmode to transparent?

<param name="wmode" value="transparent" />
雨落星ぅ辰 2024-08-18 06:49:56

您的下拉菜单将使用position:absolute

编辑:
我有一个类似的案例,顶部有一个下拉菜单,下面有一个 Flash 对象。在我的例子中,菜单有 position:absolute 和 flash 对象 wmode="opaque"
也许还值得一提的是,菜单位于带有 overflow: auto 的容器 div 和 flash 对象中。这对我有用。

好吧,让我们写下这个..

<div id="header">
    <div id="menu"></div>
</div>

<div id="flashContainer">
    <object id=flash"></object>
</div>




#header
{
    overflow: auto;
}
#header #menu
{
    position: absolute;
    top: 2px;
    left: 40px;
}
#flashContainer
{
    overflow: auto;
}
#flash
{
    float: left;
}

Your drop down menu will work with position: absolute.

Edit:
I got a similair case where I also got a dropdown menu at the top and a flash object beneath it. In my case the menu has position: absolute and the flash object wmode="opaque".
Maybe it's also worth mentioning that the menu is in a container div with overflow: auto and the flash object as well. This works for me.

Ok let's write this down..

<div id="header">
    <div id="menu"></div>
</div>

<div id="flashContainer">
    <object id=flash"></object>
</div>




#header
{
    overflow: auto;
}
#header #menu
{
    position: absolute;
    top: 2px;
    left: 40px;
}
#flashContainer
{
    overflow: auto;
}
#flash
{
    float: left;
}
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文