SWF格式视频在火狐和谷歌都能正常播放,在IE8 下不能播放,求教大神解决办法??、js代码如下:
<script src="${ct}/businessConsole/javascript/jquery-easyui-1.3.2/jquery-1.8.0.min.js"></script>
<script src="${ct}/plugins/jwplayer-6.10/jwplayer.js"></script>
<title>视频播放</title>
<style type="text/css">
#uploader {
width: 800px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id="uploader">
<div id="videoPlayer"></div>
</div>
<script type="text/javascript">
//直接通过http://127.0.0.1:8080/seas/download.tool?wjDm=fb3b8a8e-e28a-4645-ab34-011f5188965c&type=file 请求文件 视频播放不出来 可能是jwplayer 判断了视频url后缀不是视频格式(mp4 )
//改成页面加载先ajax请求通过文件代码 获取视频文件 返回视频文件名
$(function(){
$.ajax({
type : 'post',
url : '${ct}/download.tool',
data :{"wjDm":"${param.wjDm}"},
dataType : 'json',
success : function(result) {
if(result.isSucces){
var file = '${ct}/upload/'+result.url;//返回视频文件名
jwplayer.key = "7BH6PZgZMlvZhlYfcaKzMMQwzYgEHRqYYiZE0w==";
jwplayer("videoPlayer").setup({
flashplayer:'${ct}/jwplayer-6.10/jwplayer.flash.swf',
// file:'${ct}/upload/oceans.mp4',
file:file,
//file:'http://127.0.0.1:8080/seas/download.tool?wjDm=fb3b8a8e-e28a-4645-ab34-011f5188965c&type=file',
image:'${ct}/upload/videoBg.jpg',
width:500,
height:350,
dock:false,
modes:'flash'
});
}else{
alert('预览失败');
}
}
});
});