시각장애자 배려 메뉴 제작에 유용.
<style> audio {display:none;} </style> <audio id='hz' controls><source src="" type="audio/mp3" /></audio> <script> function hzplay($mp3){ hz = document.getElementById("hz"); hz.src = $mp3; hz.play(); } </script> <a href="#" onmouseover="hzplay('https://ccrma.stanford.edu/~jos/mp3/harpsi-cs.mp3')" onmouseleave="hzplay('')">mp3재생</a> 결과보기
<style>
audio {display:none;}
</style>
<audio id='hz' controls><source src="" type="audio/mp3" /></audio>
<script>
function hzplay($mp3){
hz = document.getElementById("hz");
hz.src = $mp3;
hz.play();
}
</script>
<a href="#" onmouseover="hzplay('https://ccrma.stanford.edu/~jos/mp3/harpsi-cs.mp3')" onmouseleave="hzplay('')">mp3재생</a>
결과보기
균이 님 https://sir.kr/qa/345971