+ 1
HOW TO ADD A BACKGROUND AUDIO???
how can I add a background audio to my webpage that should play automatically and loop without any controls. Does CHROME support autoplay?? https://www.dropbox.com/s/t5ji42eotis93f6/desi%20spiderman%20official%20song%20-%20SPIDERMAN%20SPOOF.mp3 can you give an example how to add this song to a web page.
5 Respuestas
+ 2
// Mozilla
<audio src="https://www.dropbox.com/s/t5ji42eotis93f6/desi%20spiderman%20official%20song%20-%20SPIDERMAN%20SPOOF.mp3?raw=1" preload loop autoplay>
</audio>
// Chrome
https://code.sololearn.com/WIZV82kvdn3e/#html
+ 1
Most browsers block autoplay. You’re better off requiring a click to start or whatever.
+ 1
Rora can it be played by clicking any where in the screen ??How???
+ 1
you can use the play() function of the audio in an onclick handler I think
+ 1
Rora can you give an example