View Full Version : I want to use does drop down menu to work with dark player


megabytes
02-15-2005, 06:05 AM
<object id="darkplayer" codeBase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1, 52,701" type="application/x-oleobject" height="0" standby="Loading Microsoft Windows Media Player components..." width="0" classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95">
<param NAME VALUE>
<param NAME="ShowControls" VALUE="0">
<param NAME="ShowStatusBar" VALUE="0">
<param NAME="ShowDisplay" VALUE="0">
<param NAME="DefaultFrame" VALUE="Slide">
<param NAME="Autostart" VALUE="1">
<param NAME="Loop" VALUE="True">
</object>

<FORM name="isc">

<select name="example" size="1" onChange="redirect(this.options.selectedIndex)">
<option selected>Artistes</option>
<option>Éric Lapointe</option>

</select>

<select name="stage2" size="1" onChange="redirect1(this.options.selectedIndex)">
<option value=" " selected>Albums</option>

</select>

<select name="stage3" size="1" onChange="redirect2(this.options.selectedIndex)">
<option value=" " selected>Chansons</option>

</select>

<script>

var groups=document.isc.example.options.length
var group=new Array(groups)
for (i=0; i<groups; i++)
group[i]=new Array()

group[0][0]=new Option("Albums"," ");

group[1][0]=new Option("Coupable"," ");


var temp=document.isc.stage2


function redirect(x){
for (m=temp.options.length-1;m>0;m--)
temp.options[m]=null
for (i=0;i<group[x].length;i++){
temp.options[i]=new Option(group[x][i].text,group[x][i].value)
}
temp.options[0].selected=true
redirect1(0)
}



var secondGroups=document.isc.stage2.options.length
var secondGroup=new Array(groups)
for (i=0; i<groups; i++) {
secondGroup[i]=new Array(group[i].length)
for (j=0; j<group[i].length; j++) {
secondGroup[i][j]=new Array() }}

secondGroup[0][0][0]=new Option("Chansons"," ");

secondGroup[1][0][0]=new Option("01 - Coupable","Musique/Eric Lapointe - Coupable/ 01 - Coupable.mp3");
secondGroup[1][0][1]=new Option("02 - Reste Là","Musique/Eric Lapointe - Coupable/ 01 - Coupable.mp3");


var temp1=document.isc.stage3
function redirect1(y){
for (m=temp1.options.length-1;m>0;m--)
temp1.options[m]=null
for (i=0;i<secondGroup[document.isc.example.options.selectedIndex][y].length;i++){
temp1.options[i]=new Option(secondGroup[document.isc.example.options.selectedIndex][y][i].text,secondGroup[document.isc.example.options.selectedIndex][y][i].value)
}
temp1.options[0].selected=true
}

function redirect2(z){
window.location=temp1[z].value
}



</script>

</FORM>

tokyo bleu
02-16-2005, 01:58 AM
I don't know if this is a newly-edited script combination, but maybe the problem is this:

secondGroup[1][0][0]=new Option("01 - Coupable","Musique/Eric Lapointe - Coupable/ 01 - Coupable.mp3");
secondGroup[1][0][1]=new Option("02 - Reste Là","Musique/Eric Lapointe - Coupable/ 01 - Coupable.mp3");

Shouldn't it be actual URLs? It's not going to play if the songs aren't uploaded.