tryhtml5_av_event_ended 在线代码实例
<p>按下播放按钮等待音频播放完成</p>
<audio id="myAudio" controls="">
<source src="/statics/demosource/horse.ogg" type="audio/ogg">
<source src="/statics/demosource/horse.mp3" type="audio/mpeg">
您的浏览器不支持 audio 元素。
</audio>
<script>
var aud = document.getElementById("myAudio");
aud.onended = function() {
alert("音频已播放完成");
};
</script>