Coding Villa Forum
FAQs
Advertisements

How can i play music on my webpage when it load?

Admin Online 6/4/2011 1:58:19 PM

Hi Guys,


I have a problem, i have created a webpage now i want to play music on it in background. Please anyone can tell me that how can i do this?

Waiting for solution....Thanks.

Share with Friends

Advertisements

Answer

Iram Online 3/26/2012 5:48:19 PM

Hi,

Different browsers have different methods of implementing embedded music files. For all versions of Netscape, as well as IE 3.0 and above, you can use the following code:

<embed src="yourmusicfile.mid" autostart="true" loop="true"
width="2" height="0">
</embed>

For Opera and all IE versions,

<bgsound src="yourmusicfile.mid" loop="infinite">
Share with Friends

Post reply

 

Enter This Code
Captcha
 

Subscribe

Email me when people reply


Subscribe to the