开发者

Why does IE8 not load the YouTube player?

I have the following mark-up to load a YouTube video player in a jQuery Tools overlay:

<a rel="#YouTubeVideo_MZKORPYI0HM" href="http://www.youtube.com/watch?v=mZkoRpyi0HM" title="Watch the YouTube video">
<img src="http://img.youtube.com/vi/mZkoRpyi0HM/2.jpg" class="youtubeThumbnail withBorder" alt="Watch the video" width="134" height="100"/>
</a>

<div id="YouTubeVideo_MZKORPYI0HM" class="overlay youtube rounded">
    <object width="640" height="505"
        type="application/x-shockwave-flash" id="YouTubeVideo_MZKORPYI0HM_Player" data="http://www.youtube.com/v/mZkoRpyi0HM?video_id=mZkoRpyi0HM&amp;versi开发者_开发知识库on=3&amp;enablejsapi=1&amp;playerapiid=ytplayer">
        <param name="allowScriptAccess" value="always">
        <param name="bgcolor" value="#cccccc">
    </object>
</div>

The page behaves exactly how I would expect in Firefox (all versions) and Chrome. However, in IE8 (and I have the latest flash plug-in), I see a "1 item remaining" message in the status bar and the overlay contains no flash player. Right-clicking on the grey space shows a "movie not loaded" message.

How can I diagnose and solve this problem with IE8?


It seems that "upgrading" my mark-up to the newer suggested technique of embedding YouTube videos, i.e. using an iframe did the trick.

The mark-up is as follows:

<iframe class="youtube-player" type="text/html" width="640" height="505" src="http://www.youtube.com/embed/mZkoRpyi0HM" frameborder="0"></iframe>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜