...

View Full Version : How to make a Quadruple-combo??



pImPaIr
07-11-2002, 08:56 PM
i Have been try real hard to modify the triple combo script but i can't seem to figure it out. here is what i have so far. Can someone please tell me what i need to change for the stage 4 to work?? I need this ASAP, Thanks!

<HTML>
<HEAD>
<TITLE>
Untitled
</TITLE>
</HEAD>
<BODY>
<FORM NAME="isc">
<TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0">
<TR ALIGN="center">
<TD NOWRAP HEIGHT="11"> &nbsp;
<SELECT NAME="example" SIZE="1" onChange="redirect(this.options.selectedIndex)">
<OPTION SELECTED>Select Report Type</OPTION>
<OPTION>Senior Management Report</OPTION>
<OPTION>Technical Management Report</OPTION>
</SELECT>
<SELECT NAME="stage2" SIZE="1" onChange="redirect1(this.options.selectedIndex)">
<OPTION VALUE=" " SELECTED></OPTION>
<OPTION VALUE=" " SELECTED>-----------------</OPTION>
<OPTION VALUE=" " SELECTED>-----------------</OPTION>
</SELECT>
<SELECT NAME="stage3" SIZE="1" onChange="redirect2(this.options.selectedIndex)">
<OPTION VALUE=" " SELECTED></OPTION>
<OPTION VALUE=" " SELECTED>-------------------</OPTION>
<OPTION VALUE=" " SELECTED>-------------------</OPTION>
</SELECT>

<SELECT NAME="stage4" SIZE="1" onChange="redirect3(this.options.selectedIndex)">
<OPTION VALUE=" " SELECTED></OPTION>
<OPTION VALUE=" " SELECTED>-------------------</OPTION>
<OPTION VALUE=" " SELECTED>-------------------</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("-------------------"," ");

group[1][0]=new Option("Now Select The Year"," ");
group[1][1]=new Option("2002 S","47");
group[1][2]=new Option("2003 S","46");

group[2][0]=new Option("Now Select The Year"," ");
group[2][1]=new Option("2002 T","115");
group[2][2]=new Option("2003 T","116");

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("-------------------"," ");
secondGroup[1][0][0]=new Option("-------------------"," ");
secondGroup[1][1][0]=new Option("Now Select Monthly or Weekly Reports"," ");
secondGroup[1][1][1]=new Option("Monthly S","");
secondGroup[1][1][2]=new Option("Weekly S","");

secondGroup[1][2][0]=new Option("Now Select Monthly or Weekly Reports"," ");
secondGroup[1][2][1]=new Option("Monthly S","");
secondGroup[1][2][2]=new Option("Weekly S","");

secondGroup[2][0][0]=new Option("-------------------"," ");
secondGroup[2][1][0]=new Option("Now Select Monthly or Weekly Reports"," ");
secondGroup[2][1][1]=new Option("Monthly T","");
secondGroup[2][1][2]=new Option("Weekly T","");

secondGroup[2][2][0]=new Option("Now Select Monthly or Weekly"," ");
secondGroup[2][2][1]=new Option("Monthly T","");
secondGroup[2][2][2]=new Option("Weekly T","");

var temp1=document.isc.stage3
function redirect(y){
for (m=temp1.options.length-1;m>0;m--)
temp1.options[m]=null
for (i=0;i<secondGroup[y].length;i++){
temp1.options[i]=new Option(secondGroup[y][i].text,secondGroup[y][i].value)
}
temp1.options[0].selected=true
redirect2(0)
}
var thirdGroups=document.isc.stage4.options.length
var thirdGroup=new Array(groups)
for (i=0; i<groups; i++) {
thirdGroup[i]=new Array(group[i].length)
for (j=0; j<group[i].length; j++) {
thirdGroup[i][j]=new Array() }}

thirdGroup[0][0][0][0]=new Option("-------------------"," ");
thirdGroup[1][0][0][0]=new Option("-------------------"," ");
thirdGroup[1][1][0][0]=new Option("-------------------"," ");
thirdGroup[1][1][1][0]=new Option("Now Select Month 2002 S"," ");
thirdGroup[1][1][1][1]=new Option("February","Senior Management Reports\Monthly\February.doc");
thirdGroup[1][1][1][2]=new Option("March","Senior Management Reports\Monthly\March.doc");
thirdGroup[1][1][1][3]=new Option("April","Senior Management Reports\Monthly\April.doc");
thirdGroup[1][1][1][4]=new Option("May","Senior Management Reports\Monthly\May.doc");
thirdGroup[1][1][1][5]=new Option("June","Senior Management Reports\Monthly\June.doc");
thirdGroup[1][1][1][6]=new Option("July","Senior Management Reports\Monthly\July.doc");

thirdGroup[1][1][2][0]=new Option("Now Select Week 2002 S"," ");
thirdGroup[1][1][2][1]=new Option("Feb1-Feb9.doc","Senior Management Reports\Weekly\Feb1-Feb9.doc");
thirdGroup[1][1][2][2]=new Option("Feb10-Feb16.doc","Senior Management Reports\Weekly\Feb10-Feb16.doc");
thirdGroup[1][1][2][3]=new Option("Feb17-Feb23.doc","Senior Management Reports\Weekly\Feb17-Feb23.doc");
thirdGroup[1][1][2][4]=new Option("Feb24-Feb28.doc","Senior Management Reports\Weekly\Feb24-Feb28.doc");
thirdGroup[1][1][2][5]=new Option("Mar1-Mar9.doc","Senior Management Reports\Weekly\Mar1-Mar9.doc");
thirdGroup[1][1][2][6]=new Option("Mar10-Mar16.doc","Senior Management Reports\Weekly\Mar10-Mar16.doc");
thirdGroup[1][1][2][7]=new Option("Mar17-Mar23.doc","Senior Management Reports\Weekly\Mar17-Mar23.doc");
thirdGroup[1][1][2][8]=new Option("Mar24-Mar31.doc","Senior Management Reports\Weekly\Mar24-Mar31.doc");


thirdGroup[1][2][0][0]=new Option("-------------------"," ");
thirdGroup[1][2][1][0]=new Option("Only in 2003"," ");
thirdGroup[1][2][1][1]=new Option("February 2003","Senior Management Reports\Monthly\"");
thirdGroup[1][2][1][2]=new Option("March 2003","Senior Management Reports\Monthly\"");

thirdGroup[1][2][2][0]=new Option("Only in 2003"," ");
thirdGroup[1][2][2][1]=new Option(" ","Senior Management Reports\Weekly");
thirdGroup[1][2][2][2]=new Option(" ","Senior Management Reports\Weekly");


thirdGroup[2][2][0][0]=new Option("-------------------"," ");
thirdGroup[2][2][1][0]=new Option("Now Select Month 2002 T"," ");
thirdGroup[2][1][1][1]=new Option("February 2003","Technical Management Reports\Monthly\February.doc");
thirdGroup[2][1][1][2]=new Option("March 2003","Technical Management Reports\Monthly\March.doc");
thirdGroup[2][1][1][3]=new Option("April 2003","Technical Management Reports\Monthly\April.doc");
thirdGroup[2][1][1][4]=new Option("May 2003","Technical Management Reports\Monthly\May.doc");
thirdGroup[2][1][1][5]=new Option("June 2003","Technical Management Reports\Monthly\June.doc");
thirdGroup[2][1][1][6]=new Option("July 2003","Technical Management Reports\Monthly\July.doc");

thirdGroup[2][1][2][0]=new Option("Now Select Week 2002 T"," ");
thirdGroup[2][1][2][1]=new Option("Feb1-Feb9.doc","Technical Management Reports\Weekly\Feb1-Feb9.doc");
thirdGroup[2][1][2][2]=new Option("Feb10-Feb16.doc","Technical Management Reports\Weekly\Feb10-Feb16.doc");
thirdGroup[2][1][2][3]=new Option("Feb17-Feb23.doc","Technical Management Reports\Weekly\Feb17-Feb23.doc");
thirdGroup[2][1][2][4]=new Option("Feb24-Feb28.doc","Technical Management Reports\Weekly\Feb24-Feb28.doc");
thirdGroup[2][1][2][5]=new Option("Mar1-Mar9.doc","Technical Management Reports\Weekly\Mar1-Mar9.doc");
thirdGroup[2][1][2][6]=new Option("Mar10-Mar16.doc","Technical Management Reports\Weekly\Mar10-Mar16.doc");
thirdGroup[2][1][2][7]=new Option("Mar17-Mar23.doc","Technical Management Reports\Weekly\Mar17-Mar23.doc");
thirdGroup[2][1][2][8]=new Option("Mar24-Mar31.doc","Technical Management Reports\Weekly\Mar24-Mar31.doc");


thirdGroup[2][2][0][0]=new Option("-------------------"," ");
thirdGroup[2][2][1][0]=new Option("Only in 2003"," ");
thirdGroup[2][2][1][1]=new Option("February 2003","Technical Management Reports\Monthly\"");
thirdGroup[2][2][1][2]=new Option("March 2003","Technical Management Reports\Monthly\"");


thirdGroup[2][2][2][0]=new Option("Only in 2003"," ");
thirdGroup[2][2][2][1]=new Option(" ","Technical Management Reports\Weekly");
thirdGroup[2][2][2][2]=new Option(" ","Technical Management Reports\Weekly");

var temp2=document.isc.stage4
function redirect3(a){
for (m=temp2.options.length-1;m>0;m--)
temp2.options[m]=null
for (i=0;i<thirdGroup[document.isc.example.options.selectedIndex][a].length;i++){
temp2.options[i]=new Option(thirdGroup[document.isc.example.options.selectedIndex][a][i].text,thirdGroup[document.isc.example.options.selectedIndex][a][i].value)
}
temp2.options[0].selected=true
}
function redirect3(a){
window.location=temp2[a].value
}
//-->
</SCRIPT>
}
//-->
</SCRIPT>
</TD>
</TR>
</TABLE>
</FORM>
</BODY>
</HTML>

jkd
07-11-2002, 09:14 PM
http://www.geocities.com/jason_YD/4combo.html



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum