1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96
| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Document sans nom</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<SCRIPT language=javascript>
var option_array = new Array();
option_array[0] = new Array("<== Sélectionner un partenaire");
option_array[1] = new Array("-- Opérateur --",
"1",
"2",
"3",
"4",
"5",
"6",
"7",
"8"
);
option_array[2] = new Array("-- Opérateur --",
"9",
"10"
);
option_array[3] = new Array("-- Opérateur --",
"11",
"12"
);
option_array[4] = new Array("-- Opérateur --",
"13",
"14",
"15",
"16",
"17",
"18",
"19"
);
option_array[5] = new Array("-- Opérateur --",
"20",
"21",
"22",
"23",
"24",
"25"
);
function switch_select()
{
for (loop = window.document.mon_formulaire.operateur.options.length-1; loop > 0; loop--)
{
window.document.mon_formulaire.operateur.options[loop] = null;
}
for (loop = 0; loop < option_array[window.document.mon_formulaire.partenaire.selectedIndex].length; loop++)
{
window.document.mon_formulaire.operateur.options[loop] = new Option(option_array[window.document.mon_formulaire.partenaire.selectedIndex][loop]);
}
window.document.mon_formulaire.operateur.selectedIndex = 0;
}
function set_orig()
{
window.document.mon_formulaire.partenaire.selectedIndex = 0;
window.document.mon_formulaire.operateur.selectedIndex = 0;
}
window.onload=set_orig
</SCRIPT>
</head>
<body>
<form action="" method="get" name="mon_formulaire">
<select name="partenaire" onChange="switch_select();">
<option>--Choix--</option>
<option>je</option>
<option>tu</option>
<option>il</option>
<option>nous</option>
<option>vous</option>
</select>
<select name="operateur">
<option></option>
</select></form>
</body>
</html> |