在IE
版本11.1206.15063.0CO
中,嵌入的视频文件会在大约3秒钟后停止播放。它们在IE
版11.0.10240.17443CO
的早期版本以及Google Chrome
和Mozilla FireFox
中工作。 MP4
文件也可在所有媒体播放器中使用。该代码在调用时在iframe中打开。这是被调用的代码。
<html>
<head>
<meta name="google" value="notranslate" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>VA Getting to the POINT Aug 18</title>
<style>
html, body {
margin: 0px;
padding: 0px;
font-family:Verdana, Geneva, sans-serif;
background-color: #1a1a1a;
text-align: center;
width: 100%;
height: 100%;
}
</style>
<link href="" rel="stylesheet" type="text/css">
</head>
<body>
<video width="980" height="540" controls>
<source src="VA_Getting_to_the_POINT_Aug_2018.mp4" type="video/mp4" />
<source src="VA_Getting_to_the_POINT_Aug_2018.webm" type="video/webm" />
<embed src="VA_Getting_to_the_POINT_Aug_2018.mp4" type="application/x-shockwave-flash" width="980" height="570" allowscriptaccess="always" allowfullscreen="true" autoplay="false"></embed> <!--IE 8 - add 25-30 pixels to vid height to allow QT player controls-->
</video>
</body>
</html>
我尝试将元内容更改为不同的IE
版本,以及从视频标签内部删除embed标签和webm
文件。我尝试更改视频文件的编码以及对html文件的其他修改。我目前正在检查.jsp
文件,该文件也会调用该代码。我尝试的所有内容仍然可以在Chrome和Firefox中运行,而不仅限于此版本的IE
11。
偶尔还会弹出一个错误消息,提示错误:不支持的视频类型或无效的路径,错误:无法解码视频。
任何帮助或建议,将不胜感激。
谢谢。
答案 0 :(得分:0)
IE需要H.264或MPEG-4编解码器,而您未指定它们。.
尝试以下代码
<video width="980" height="540" controls>
<source src="VA_Getting_to_the_POINT_Aug_2018.mp4" type="video/mp4" codecs="H.264/MPEG-4"/>
<source src="VA_Getting_to_the_POINT_Aug_2018.webm" type="video/webm" />
<embed src="VA_Getting_to_the_POINT_Aug_2018.mp4" type="application/x-shockwave-flash" codecs="H.264/MPEG-4" width="980" height="570" allowscriptaccess="always" allowfullscreen="true" autoplay="false"></embed> <!--IE 8 - add 25-30 pixels to vid height to allow QT player controls-->
</video>
this link上的最新信息,支持等
答案 1 :(得分:0)
正如我所说,我在IE中也有同样的问题,添加preload =“ auto”解决了我的问题。 您可以尝试以下类似方法。
<video width="980" height="540" controls preload="auto">
<source src="VA_Getting_to_the_POINT_Aug_2018.mp4" type="video/mp4" />
<source src="VA_Getting_to_the_POINT_Aug_2018.webm" type="video/webm" />
<embed src="VA_Getting_to_the_POINT_Aug_2018.mp4" type="application/x-shockwave-flash" width="980" height="570" allowscriptaccess="always" allowfullscreen="true" autoplay="false"></embed> <!--IE 8 - add 25-30 pixels to vid height to allow QT player controls-->
</video>
但是添加预加载可能并非总是一件好事,因此仅在Internet Explorer允许的情况下才可以添加此属性,而其余部分则可以保留。