Article View: bit.listserv.script-l
Article #162Could you FINISH my script? (select
From: sadacia
Date: Sat, 24 May 1997 00:00
Date: Sat, 24 May 1997 00:00
51 lines
2150 bytes
2150 bytes
Subject: Could you FINISH my script? (selecting a midi file as background sound)
Hello, I want to select a midi song to play in this way :
from a form ('select' kind) I want to give the election of three songs.
When the web visitor selects one, the selected song has to start to play. I
though in this way as a possibility.
<HTML>
<HEAD> <TITLE>SELECTING A SONG</TITLE>
<SCRIPT LANGUAGE="JavaScript">
var Extension=".mid";
var MidiSong=Song+Extension;
function Play(MidiSong){
document.play(MidiSong); // or 'bgsound.start(MidiSong)' or some metod
to play the song (if it exists)
}
</SCRIPT>
</HEAD>
<BODY>
<FORM>
<SELECT NAME="Song" SIZE="0" onFocus="this...........> <! here is where
comes the onFocus instruction for sending to the
song that has to play to the 'Song' variable.>
<OPTION>Song number one <!value1, for example song1>
<OPTION>Song number two <!value2, for example song2>
<OPTION>Song number three <!value3, for example song3>
</SELECT>
</FORM>
<SCRIPT LANGUAGE="JavaScript">
Play(MidiSong);
</SCRIPT>
</BODY>
</HTML>
I don't have idea of what is the instruction for the 'onFocus' message',
but it has to return the name of the song (song1, song2, song3) and in the
drop down box has to appear the description of them. So in the script, the
Play function, plays the selected song (song1.mid, song2.mid, song3.mid).
Of course that I suppose that there is a metod to execute a midi file
because if not, I am lost. Or no?
Do you understand what I am asking for ? It would be very usefull. ah!
excuse my poor English (I am from Spain)
Please, I would be very thankfull if you can give me a gide to do it.
Greetings : Juan Carlos Muro
sadacia@arrakis.es
http://www.arrakis.es /~abulafia/Sadacia/Sadacia.html
Technical Details
Message-ID:
<01bc683f$b5566e20$514e05c3@sadac>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11353d,fc1b84ba505620da,start X-Google-Attributes: gid11353d,public From: sadacia@arrakis.es Subject: Could you FINISH my script? (select Date: 1997/05/24 Message-ID: <01bc683f$b5566e20$514e05c3@sadac> X-Deja-AN: 243683076 X-Gateway: notes@gn.apc.org Newsgroups: bit.listserv.script-l