»
EnglishFrenchVietnamese

Print - Web midi JukeBox - JavaScriptBank.com

Full version: jsB@nk » Multimedia » Sound » Web midi JukeBox
URL: https://www.javascriptbank.com/web-midi-jukebox.html

Web midi JukeBox © JavaScriptBank.comWeb midi JukeBox that will allow you pick either a .mid of .wav file and play it from a dropdown list.

Full version: jsB@nk » Multimedia » Sound » Web midi JukeBox
URL: https://www.javascriptbank.com/web-midi-jukebox.html



JavaScript
<SCRIPT language=JavaScript>// Web midi JukeBox application// © Rochelle// rochelle@freenet.co.ukfunction playit(){// halt any current selected played music filevar mloop = document.selform.music.length;mloop--;for (num = 0; num < mloop; num++){document.embeds[num].stop();}// play music selectedvar sel = document.selform.music.selectedIndex;if (sel != 0) {sel--;document.embeds[sel].play();}}</SCRIPT><!--    This script downloaded from www.JavaScriptBank.com    Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->


HTML
<BODY onload="document.all.selform.style.visibility = 'visible';"><FORM name=selform><P>Web JukeBox <SELECT style="VERTICAL-ALIGN: middle" onchange=playit(); size=1 name=music hidden??> <OPTION value=0 selected>- select music (stopped)</OPTION> <OPTION value=1>Sound Filename title 1</OPTION> <OPTION   value=2>Sound Filename title 2</OPTION> <OPTION value=3>Sound Filename title 3</OPTION> <OPTION value=4>Sound Filename title 4</OPTION> <OPTION   value=5>Sound Filename title 5</OPTION></SELECT></P></FORM><!-- alter the text between above option tags for your desired midi sound file named title. You can add as many sound files to the drop-down menu but increment the numerical value by one beyond those shown above and ensure the same number of music titles is less than one in your list of embed sound files shown in step four below --><!-- END STEP THREE: Proceed to step FOUR below  --><!-- STEP FOUR: Copy the following HTML code to be the last embed tag itmes before your end /BODY tag of your HTML document  --><EMBED src=soundfilename1.mid hidden=true autostart="false" width="128" height="128"> <EMBED src=soundfilename2.mid hidden=true autostart="false" width="128" height="128"> <EMBED src=soundfilename3.mid hidden=true autostart="false" width="128" height="128"> <EMBED src=soundfilename4.mid hidden=true autostart="false" width="128" height="128"> <EMBED src=soundfilename5.mid hidden=true autostart="false" width="128" height="128"></BODY><!--    This script downloaded from www.JavaScriptBank.com    Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->