Safari Browser Audio.Play() Is Not Working

Why can't JavaScript .play() audio files on iPhone safari?

iOS disables autoplay, instead requiring that play be initiated as part of a user interaction (e.g., you can start playback within a touchstart listener). There's a bit of documentation about this on Apple's developer documentation. There's also this article Overcoming iOS HTML5 audio limitations on IBM's developer site that has examples and more detail.

.play() function not working on safari browser with audio tag

try a different format. Wav files may not be supported.

Html 5 Audio is not working in iphone safari browser

Did like below code and solved problem

Added two lines before play

audio1.load();
audio2.load();

audio1.play();
audio1.on('ended' function(){
audio2.play();
});

HTML5 Audio object doesn't play in Safari

About iPhone Safari: It seems play() work when launched by an onclick event.
See http://groups.google.com/group/iphonewebdev/browse_thread/thread/91e31ba7ae25e6d4?hl=en



Related Topics



Leave a reply



Submit