wwa*_*waw 5 javascript audio html5-video html5-audio
查看此演示页面:http://www.phon.ucl.ac.uk/home/mark/audio/play10.htm
Play Sound快速连续单击该按钮两次。因为当您再次点击按钮时,第一次播放尚未完成,所以什么也没有发生,并且点击似乎被忽略了。如何对其进行重新编码,以便停止当前播放,将播放位置重置到声音的开头,并在每次单击按钮时重新启动Play Sound?
你可以把它改成这样
var thissound=document.getElementById('audioElemID');
thissound.currentTime=0;
thissound.play();