视频与“添加此”重叠IE 中的窗口!

发布于 2024-08-12 12:11:29 字数 3736 浏览 2 评论 0原文

我有一个 HTML 简单页面,其中有一个“添加此”按钮(实际上是“共享”按钮)和一些视频。我的问题是,当我单击“共享”按钮时,浏览器屏幕中央会弹出一个小窗口(div),使其位置保持不变。

当我滚动窗口时,此“添加此”窗口会与页面上的视频重叠。这在 Firefox 中效果很好,但在 IE 和 Chrome 中则不然。

这是我的代码:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title></title>
    <style type="text/css">
        #at16p, #atie6ifh
        {
            overflow-y: auto !important;
        }        
    </style>
</head>
<body>
    <!-- AddThis Button BEGIN -->
    <a class="addthis_button" style="text-align: right;" href="http://addthis.com/bookmark.php?v=250&amp;pub=xa-4ac61e0801642c41">
        <img src="http://s7.addthis.com/static/btn/v2/lg-share-en.gif" width="125" height="16"
            alt="Bookmark and Share" style="border: 0" /></a><script type="text/javascript" src="http://s7.addthis.com/js/250/addthis_widget.js#pub=xa-4ac61e0801642c41"></script>

    <!-- AddThis Button END -->
    <center>
        <div id="divVideoDisplay" runat="server" style="width: 100%; padding-bottom: 20px;
            z-index: -10000; overflow: hidden;">
            <br />
            <h1>
                First Video</h1>
            <br />
            <object type='application/x-shockwave-flash' data='http://www.videowebtown.com/community/newlightplayer/flvplayer.swf?file=http%3A%2F%2Fsq.txdnl.com%2Fvwt%2Fd%2Fa%2Fv%2Fi%2Fdavidmarsh98%2Fvideo%2F26198%2FFLV%2F98188.flv' style="z-index: -1;" 
                width='640' height='480' bgcolor='FFFFFF' border='1'>
                <param name='movie' value='http://www.videowebtown.com/community/newlightplayer/flvplayer.swf?file=http%3A%2F%2Fsq.txdnl.com%2Fvwt%2Fd%2Fa%2Fv%2Fi%2Fdavidmarsh98%2Fvideo%2F26198%2FFLV%2F98188.flv'/>
                <param name='bgcolor' value='FFFFFF'/>
                <param name='Windowless' value='true'/>
                <embed src='http://www.videowebtown.com/community/newlightplayer/flvplayer.swf?file=http%3A%2F%2Fsq.txdnl.com%2Fvwt%2Fd%2Fa%2Fv%2Fi%2Fdavidmarsh98%2Fvideo%2F26198%2FFLV%2F98188.flv'
                    quality='high' bgcolor='#ffffff' width='640' height='480' name='movie' allowscriptaccess='sameDomain'
                    type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer'
                    border='1'>
            </object>
            <br>
            <b style="color: red">FREE</b> service provided by <a href='http://www.videowebtown.com'
                target='_new'><u>VideoWebTown.com</u></a>
            <br />
            <h1>
                Second Video</h1>
            <br />
            <object width="425" height="344" style="z-index: -1;" >
                <param name="movie" value="http://www.youtube.com/v/rrrx9izp0Lc&hl=en_US&fs=1&">
                </param>
                <param name="allowFullScreen" value="true"></param>
                <param name="allowscriptaccess" value="always"></param>
                <param name='Windowless' value='true'/>
                <embed src="http://www.youtube.com/v/rrrx9izp0Lc&hl=en_US&fs=1&" type="application/x-shockwave-flash"
                    allowscriptaccess="always" allowfullscreen="true" width="425" height="344">
        </embed>
            </object>
        </div>
    </center>

</body>

</html>

任何帮助/评论表示赞赏。

I have a HTML simple page with a ADD THIS button (the share button actually) and some videos on it. My problem is that when I click on the SHARE button and a small window (a div) pop ups on the center of the browser screen which is keeps it position constant there.

When I scroll the window, this ADD THIS window gets overlapped by the videos on the page. This works good in Firefox but not in IE and Chrome.

Here is my code:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title></title>
    <style type="text/css">
        #at16p, #atie6ifh
        {
            overflow-y: auto !important;
        }        
    </style>
</head>
<body>
    <!-- AddThis Button BEGIN -->
    <a class="addthis_button" style="text-align: right;" href="http://addthis.com/bookmark.php?v=250&pub=xa-4ac61e0801642c41">
        <img src="http://s7.addthis.com/static/btn/v2/lg-share-en.gif" width="125" height="16"
            alt="Bookmark and Share" style="border: 0" /></a><script type="text/javascript" src="http://s7.addthis.com/js/250/addthis_widget.js#pub=xa-4ac61e0801642c41"></script>

    <!-- AddThis Button END -->
    <center>
        <div id="divVideoDisplay" runat="server" style="width: 100%; padding-bottom: 20px;
            z-index: -10000; overflow: hidden;">
            <br />
            <h1>
                First Video</h1>
            <br />
            <object type='application/x-shockwave-flash' data='http://www.videowebtown.com/community/newlightplayer/flvplayer.swf?file=http%3A%2F%2Fsq.txdnl.com%2Fvwt%2Fd%2Fa%2Fv%2Fi%2Fdavidmarsh98%2Fvideo%2F26198%2FFLV%2F98188.flv' style="z-index: -1;" 
                width='640' height='480' bgcolor='FFFFFF' border='1'>
                <param name='movie' value='http://www.videowebtown.com/community/newlightplayer/flvplayer.swf?file=http%3A%2F%2Fsq.txdnl.com%2Fvwt%2Fd%2Fa%2Fv%2Fi%2Fdavidmarsh98%2Fvideo%2F26198%2FFLV%2F98188.flv'/>
                <param name='bgcolor' value='FFFFFF'/>
                <param name='Windowless' value='true'/>
                <embed src='http://www.videowebtown.com/community/newlightplayer/flvplayer.swf?file=http%3A%2F%2Fsq.txdnl.com%2Fvwt%2Fd%2Fa%2Fv%2Fi%2Fdavidmarsh98%2Fvideo%2F26198%2FFLV%2F98188.flv'
                    quality='high' bgcolor='#ffffff' width='640' height='480' name='movie' allowscriptaccess='sameDomain'
                    type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer'
                    border='1'>
            </object>
            <br>
            <b style="color: red">FREE</b> service provided by <a href='http://www.videowebtown.com'
                target='_new'><u>VideoWebTown.com</u></a>
            <br />
            <h1>
                Second Video</h1>
            <br />
            <object width="425" height="344" style="z-index: -1;" >
                <param name="movie" value="http://www.youtube.com/v/rrrx9izp0Lc&hl=en_US&fs=1&">
                </param>
                <param name="allowFullScreen" value="true"></param>
                <param name="allowscriptaccess" value="always"></param>
                <param name='Windowless' value='true'/>
                <embed src="http://www.youtube.com/v/rrrx9izp0Lc&hl=en_US&fs=1&" type="application/x-shockwave-flash"
                    allowscriptaccess="always" allowfullscreen="true" width="425" height="344">
        </embed>
            </object>
        </div>
    </center>

</body>

</html>

Any help/comments appreciated.

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

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

发布评论

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

评论(2

黯淡〆 2024-08-19 12:11:29

这段代码需要

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

添加到对象标签中,并且 标签需要一个 wmode="transparent" 属性。

这对我有用。

Well this code required

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

to be added to the object tag and also the <embed> tag required an attribute as wmode="transparent".

i.e. <embed wmode="transparent" ... />

This worked for me.

笑饮青盏花 2024-08-19 12:11:29

尝试添加

这是 IE 中众所周知的错误,但我不确定为什么它在 Chrome 中不起作用,所以我希望这能解决两个浏览器的问题。另外,你检查过 Z-index 来确定吗? (这对于 IE 来说无关紧要,但对于 Chrome 来说可能)

Try adding <param name="wmode" value="transparent">

This is a well-known bug in IE, but I'm not sure why it doesn't work in Chrome, so I'm hoping this will solve it for both browsers. Also, have you checked the Z-index just to be sure? (This doesn't matter for IE, but it might for Chrome)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文