非常感谢你的解决方案。
这是我的来源:
<div class="media-player">
<script>
$(document).ready(function() {
$("#jquery_jplayer_foot_mob_1").jPlayer({
ready: function() {
$(this).jPlayer("setMedia", {
title: "4D - Zelený dym",
oga:"http://www.jplayer.org/audio/ogg/Miaow-07-Bubble.ogg",
mp3: "files/audio/4D---Zeleny-dym-(2012).mp3"
});
},
play: function() { // To avoid multiple jPlayers playing together.
$(this).jPlayer("pauseOthers");
},
errorAlerts: true,
supplied: "oga, mp3",
swfPath: "scripts/jplayer",
solution: "html",
cssSelectorAncestor: "#jp_container_foot_mob_1"
});
});
</script>
<div id="jquery_jplayer_foot_mob_1" class="jp-jplayer"></div>
<div id="jp_container_foot_mob_1" class="jp-audio small cover">
<div class="jp-type-single">
<div class="jp-cover">
<img src="styles/img/disc_1.png" />
</div>
<div class="jp-gui jp-interface">
<ul class="jp-controls">
<li class="left"><a href="javascript:;" class="jp-play" tabindex="1">play</a></li>
<li class="right"><a href="javascript:;" class="jp-pause" tabindex="1">pause</a></li>
<div class="clear"></div>
</ul>
<div class="jp-progress">
<div class="jp-seek-bar">
<div class="jp-play-bar"></div>
</div>
</div>
<div class="jp-details">
<span class="jp-title"></span>
<div class="jp-time-holder">
<div class="jp-current-time"></div>
</div>
</div>
</div>
<div class="jp-no-solution">
<span>Update Required</span>
To play the media you will need to either update your browser to a recent version or update your <a href="http://get.adobe.com/flashplayer/" target="_blank">Flash plugin</a>.
</div>
</div></div>
答案 0 :(得分:4)
答案 1 :(得分:2)
尝试更改代码以分配m4a而不是mp3,但仍然保持与mp3的链接。这对我有用:
$(document).ready(function() {
$("#jquery_jplayer_foot_mob_1").jPlayer({
ready: function() {
$(this).jPlayer("setMedia", {
title: "4D - Zelený dym"
m4a: "files/audio/4D---Zeleny-dym-(2012).mp3"
});
},
play: function() { // To avoid multiple jPlayers playing together.
$(this).jPlayer("pauseOthers");
},
errorAlerts: true,
supplied: "m4a",
swfPath: "scripts/jplayer",
solution: "html",
cssSelectorAncestor: "#jp_container_foot_mob_1"
});
});