0
How do I play an audio instance in Safari?
var som = new Audio("http://www.sousound.com/music/healing/healing_01.mp3");
function tocar() {
this.play();
}
som.addEventListener('canplay', tocar, false);
See that in this example it does not work on Safari.
In this reply, https://stackoverflow.com/a/31777081/4312593, you comment on the possibility of disabling automatic playback.
– Netinho Santos
Put text between tags
<audio ...>Não suportado</audio>
... If text is displayed, the tag is not compatible with the browser. Then there is nothing you can do, except another way to incorporate sound in this browser.– Sam
Your jsFiddle works for me on Safari...
– Sergio
Yes, it works, but it takes time to load.
– Ivan Ferrer