The following is the HTML code:
Copy code code as follows:
<! Doctype html public "-// W3C // dtd html 4.0 transitional // en">>
<Html>
<Head>
<Title> New Document </Title>
<Meta name = "general" content = "editplus">
<Meta name = "author" content = "">
<Meta name = "keywords" content = "">
<Meta name = "description" content = "">
</Head>
<!-by Sundful Starting->
<body>
<script language = "javascript">
var subcat = new array ();
subcat [0] = New Array ('Chinese', 'English', 'English')
subcat [1] = New Array ('Chinese', 'French', 'French')
subcat[2] = new Array('English','Chinese','Chinese')
subcat[3] = new Array('French','Chinese','Chinese')
Function Changeselect1 (local) (local)
{{
document.form1.s2.length = 0; // initialize the drop -down data
document.form1.s2.Options [0] = New Option ('== Please select ==', ''); // Give the first value to the first value
for (i = 0; I <subcat.length; i ++) // leggh = 20
{{
if (subcat [i] [0] == local) // [0] [1] The first column of the first column
{document.form1.s2.Options [document.form1.s2.length] = New Option (subcat [i] [1], subcat [i]);} // establishment option
// The first length = 1 because there is == Please select ==
// I = 9 o'clock length = 10 value is 11 because the subcat [i] [0] == LOCATIDID is shielded from 0
}
}
</script>
<form name = "form1" method = "Post" runat = "Server">
Secondary linkage:
<select name="s1" onChange="changeselect1(this.value)">
<option> == Please select == </option>
<option value = "Chinese"> Chinese </option>
<option value = "English"> English </option>
<option value = "English"> French </option>
</select>
<select name = "s2">
<option> == Please select == </option>
</select>
</form>
<!-by Sundful Ending->
</Body>
</Html>