在IE8中出现这种情况我错过了什么?

时间:2015-04-15 14:00:14

标签: javascript internet-explorer-8 html5-video video.js

我在网页上有几个video-js播放器代码:

<video id="vid1" class="video-js vjs-default-skin" width="140" height="120"
controls poster="/1video/countdown.jpg" data-setup='{}'>
<source src="/video/test.mp4" type="video/mp4" />
</video>

这在标题中:

 <link href="/video-js-4.12.5/video-js/video-js.css" rel="stylesheet">
 <script src="/video-js-4.12.5/video-js/video.js"></script>
 <script>videojs.options.flash.swf = "/video-js-4.12.5/video-js/video-js.swf"</script>

我需要添加什么才能让玩家出现在IE8中?任何帮助将不胜感激。

1 个答案:

答案 0 :(得分:0)

不幸的是,Internet Explorer 8不支持您正在使用的<video/>标记。

Source

<强>更新

当在不支持HTML5视频的浏览器(例如IE 8)中加载时,

video.js应该回退到Flash。你的不工作可能有几个原因:

  1. Ensure that poster image is set
  2. Use a self hosted version of video.js rather than the CDN. Then ensure that your path to video-js.swf is accurate within the JS file
  3. Ensure that your flash plugin is up-to-date
  4. 没有。 2可能与您的问题最相关。我看到你在标题中尝试更改选项。也许尝试删除它,并确保video.js中的文件路径是准确的(打开JS文件并搜索video-js.swf)。