HTML Sound

The BGSOUND element is used to play sounds on a web page. There is no end tag for the <bgsound> element. To play sounds all that is required is to put a line like the following on your web page:

<bgsound src="1234usmc.wav" loop="-1">

This line is used on this page to play sound.


BGSOUND element attributes

  • SRC="1234usmc.wav" - The location or the URL of the WAV, MIDI, or AU file to play.
  • LOOP="-1" - The number of times the file will will loop. A value of INFINATE or -1 will loop indefinitely.