Thunderman54
asked on
Can you do onLoad audio with other browsers such as Safari, Android, etc.
Haven't done a ton of research on this. Figured I'd "ask the experts" and use my paid subscription. I pasted the following code in my browser (Chrome - see below) . Works fine on Windows. Won't work (play as page loads) on my Asus tablet (Android). Haven't tested on my wife's Mac notebook yet or her iPad, but from what I'm reading online I don't think it's going to work on those devices either. Should it work in all browsers on all devices? Something I'm overlooking? Any work-arounds? I just have a 6 second audio clip I want to play as the web page loads, but I'd like to get it to work on all browsers/devices, if possible. Of course, I do understand, even if it is possible, there's no guarantee the user will have his/her speakers turned on and the volume turned up. BTW, I don't want any controls visible on the page.
<embed src="whistle.mp3" autostart="true" hidden="true" loop="false"></embed>
<embed src="whistle.mp3" autostart="true" hidden="true" loop="false"></embed>
ASKER
Since I posted my question I see where the audio tag has "autoplay" as one of the control properties. Do some of the browsers/devices not support this? Do you know? As I said, haven't done a lot of testing - obviously - but that seems to be what some are saying on the Internet as I do some research on this issue.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Open in new window
There are options for the controls and what not too.
source: http://www.w3schools.com/tags/tag_audio.asp