How to add Sound using html code

-->

To add sounds to a web page. You will use the <EMBED> tag

This tag supports many common sound file formats... such as ..wav .wma .au .mp3 .mpg .mpeg .avi, .mid

Example Code Syntax :

Creating a player

<embed src="soundfile.mid" width="x" height="x" autostart="x" hidden="x" loop="x" volume="x"></embed>

Width : the width of the media player.

Height : the height of the media player.

To make the music play automatically the parameter is Autostart="TRUE"
You can put "FALSE" instead of "TRUE" so the person visiting your page will have to click on the play button for it to start.

Hidden - if this value is true then the media player will not be displayed. (Values are true/false)

Volume - set the volume of the media file. The range is 0-100. (default is 50)

loop - sets the media file to repeat or not

Normally the file will stop playing after it is completed the first time. so if you want it to start over once it is done use the attribute loop="true"

loop="true" ; bgsound sound continuously. (Values are true/false)

You can also use a number value to loop the sound a specific amount of times, for example loop="3" will play the background sound three times, then stop.