1
在我的页面中有一些mp3链接,我使用jplayer。点击单独链接时如何更新jplayer函数播放?jplayer在单个页面中的多个mp3链接
$(document).ready(function() {
$("#jquery_jplayer_1").jPlayer({
ready: function(event) {
$(this).jPlayer("setMedia", {
mp3: "test_1.mp3", //my mp3 file
});
},
swfPath: "http://www.jplayer.org/2.1.0/js",
supplied: "mp3"
});
});
我的MP3链接:
<a href="javascript:listen(1);" class="jp-play" ></a>
<a href="javascript:listen(2);" class=" jp-play" ></a>
<a href="javascript:listen(3);" class=" jp-play" ></a>
<a href="javascript:listen(4);" class=" jp-play" ></a>
<a href="javascript:listen(5);" class=" jp-play" ></a>
它不工作的第二个链接,当它点击它test_1.mp3播放 – user1264362
,因为你没有一个名为'test_2.mp3'的MP3 – mgraph
在这个链接每次test1.mp3播放。我不明白为什么。 http://www.dilyurdu.com/audio.htm – user1077300