jplayer for video 仅适用于 Chrome - 不适用于 FireFox 或 IE8
我没有找到对此的太多支持,所以我猜测我的 jQuery 有一个简单的问题。任何原因为什么这只能在 Chrome 中播放,而不能在 FireFox 7.0.1 或 IE8 中播放
<script type="text/javascript">
$(document).ready(function () {
$("#jquery_jplayer_1").jPlayer({
ready: function () {
$(this).jPlayer("setMedia", {
m4v: "Media/sample_iPod.m4v"
}).jPlayer("play");
},
swfPath: "../Data/Sites/1/skins/CCG/js/Jplayer.swf",
supplied: "m4v",
size: {
width: "640px",
height: "360px",
cssClass: "jp-video-360p"
}
});
});
</script>
<div id="jquery_jplayer_1" class="jp-jplayer">
</div>
任何帮助都值得赞赏。
I'm not finding much support for this, so I'm guessing there's a simple problem with my jQuery. Any reason why this would only play in Chrome, but not FireFox 7.0.1 or IE8
<script type="text/javascript">
$(document).ready(function () {
$("#jquery_jplayer_1").jPlayer({
ready: function () {
$(this).jPlayer("setMedia", {
m4v: "Media/sample_iPod.m4v"
}).jPlayer("play");
},
swfPath: "../Data/Sites/1/skins/CCG/js/Jplayer.swf",
supplied: "m4v",
size: {
width: "640px",
height: "360px",
cssClass: "jp-video-360p"
}
});
});
</script>
<div id="jquery_jplayer_1" class="jp-jplayer">
</div>
Any help is appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
注意:这是针对音频的,但我想它对于视频也同样有效,所以你可以尝试一下。
我浪费了一整天的时间试图让它在 ie8 上运行,但是当你查看 jPlayer 主页上的演示时,它们也无法运行。微软应该宣布 IE8 死亡。
有了这个,我至少设法让它与 FF、Chrome 和 Safari 一起工作。据我了解 2.1.0 版本有问题,他们的 google 小组中的一些人建议降级到 2.0.0
Note: this is for audio, but I guess it would work the same with video, so you could give it a try.
I've wasted my whole day tryin to get this to work on ie8, but as you look at the demos on jPlayer's homepage, they also wont work. Microsoft should declare IE8 dead.
With this I managed atleast to get it working with FF,Chrome and Safari. As I understand there is something wrong with the 2.1.0 version, some people in their google group advise downgrading to 2.0.0
我的理解是,如果浏览器回退到 Flash,它将从用户位置而不是服务器位置调用媒体。尝试对您的媒体使用绝对网址。
My understanding is that if the browser falls back to flash it will be calling the media from the user's location, not the server location. Try using absolute urls to your media.
就我而言,有一大堆问题阻止了 jPlayer 在 IE8 中工作:
终于成功了!
In my case there were a whole pile of issues stopping jPlayer working in IE8:
Finally it worked!