English 中文(简体)
我如何把YouTube闪电视频超支问题放在IE & Zheng的Ajax popup窗层?
原标题:How do I fix a YouTube flash video overlay problem on a ajax popup window layer in IE & Chrome?

如果你去下面的现场,你就会看到一个你的管录像,但如果你选择下面任何产品上加的 car子,那么一个掩饰窗就显示汽车上的产品。 然而,YouTube视频通过它播放。 难道这是一个Z-index问题,还是我需要把某些方面加入从YouTube上embe的法典? 问题只在Windows on Zheng & IE。 海运局在任何浏览器中没有出现这一问题。 我没有在视窗上检查Safari。

http://www.uniafibre.com/pages/Power-Scour-.html

下面是问题简介。

“The

最佳回答

http://www.scorchsoft.com/news/youline-z-index-embed-iframe-fix>。

不要把你的管子 like成像:

<iframe title="YouTube video player" width="480" height="390" src="http://www.youtube.com/embed/lzQgAR_J1PI" frameborder="0" wmode="Opaque">

添加吗?

<iframe title="YouTube video player" width="480" height="390" src="http://www.youtube.com/embed/lzQgAR_J1PI?wmode=transparent" frameborder="0" wmode="Opaque">

This worked a charm for me.

问题回答
$(document).ready(function ()
 {$( iframe ).each(function()
     {var url = $(this).attr("src");
      var result = url.search(/youtube/i);
      if(result!=-1)
       {result = url.indexOf( ? );
        if(result!=-1)  
          {$(this).attr("src",url+"&wmode=transparent");
          } else {$(this).attr("src",url+"?wmode=transparent");}
       }
     });
 });

这将为与你管有关的所有金字塔确定z。 要求做工作。 将该守则放在空白卷宗中,并将其列入源代码。 希望这一帮助

并不确定如何用嵌入的镜子来做到这一点,但闪光电影需要附加参数:

wmode:"transparent" //instead of transparent you can also put opaque

闪光电影在拥有一席之地之前不会听z-index。

你们可以通过将住所设置为“opaque”来解决这个问题。

<object width= 425  height= 344 > 
    <param name= movie  value= http://www.youtube.com/v/Wj_JNwNbETA&hl=en&fs=1 > 
    <param name= type  value= application/x-shockwave-flash > 
    <param name= allowfullscreen  value= true > 
    <param name= allowscriptaccess  value= always > 
    <param name="wmode" value="opaque" />
    <embed width= 425  height= 344 
            src= http://www.youtube.com/v/Wj_JNwNbETA&hl=en&fs=1 
            type= application/x-shockwave-flash 
            allowfullscreen= true 
            allowscriptaccess= always 
            wmode="opaque"
    ></embed> 
    </object>

For iframe embeds loading vids dynamically with youtube s api (rather than with hard-coded iframe elements), you can change the player object like so:

     player = new YT.Player( show , {
          height:  540 ,
          width:  960 ,
          videoId: firstID,
          playerVars: { rel:0,modestbranding:1, wmode: "transparent" },
          events: {
         onStateChange : onPlayerStateChange
}

        });




相关问题
Image rendered with wrong colors in IE8

I have a gradient image as a PNG (no transparency) in a web-page. By taking a screenshot of Chrome showing the page and cropping the image from the page, I see the exact same colors are drawn as the ...

Determine Mobile Internet Explorer version

I need to determine the version of Mobile Internet Explorer on a Windows Mobile 6.1 device. So that I can report the same user-agent string as is being used by Mobile Internet Explorer. The user-...

CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

Internet Explorer only part loading JavaScript/CSS

I m having trouble with my local development environment where IE (6 through to 8) is only part loading JavaScript/CSS files. It throws random errors at random places in jquery.min.js every time I ...

IE doesn t run Javascript when you click back button

I ve built a shop with tons of JS running. One of the pieces of the cart, is a zip code field which is required to calculate shipping cost. This works fine going through the cart. Now clicking ...

热门标签