Reputation:
I am making a game in an HTML web page. How would I add music to this game?
Upvotes: 0
Views: 6264
Reputation: 2101
Try this
<embed src="success.wav" autostart=false loop=false>
You may use javascript also
function func1() {
document.all.sound.src = "sound.wav"
}
window.onload=func1;
Upvotes: 1
Reputation: 33217
<embed src="bgsound.mp3" autostart="true">
http://www.htmlf1.com/tutorial/html-background-music.html
Upvotes: 3