The following is the html code:
Copy codeThe Code is as follows:
<! Doctype html public "-// W3C // dtd html 4.0 Transitional // EN">
<HTML>
<HEAD>
<TITLE> New Document </TITLE>
<Meta name = "Generator" 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 (locationid)
{
Document. form1.s2. length = 0; // initialize the drop-down list to clear the drop-down data
Document. form1.s2. options [0] = new Option ('= select =', ''); // give the first value
For (I = 0; I <subcat. length; I ++) // leader = 20
{
If (subcat [I] [0] = locationid) // [0] [1] First column and second column
{Document. form1.s2. options [document. form1.s2. length] = new Option (subcat [I] [1], subcat [I] [2]);} // create an option
// The first time length = 1 because there is = Please select =
// When I = 9, there are 11 length = 10 values because subcat [I] [0] = locationid is blocked and then written.
}
}
</Script>
<Form name = "form1" method = "post" runat = "server">
Secondary linkage:
<Select name = "s1" onChange = "changeselect1 (this. value)">
<Option >== select ==</option>
<Option value = ""> Chinese </option>
<Option value = "English"> English </option>
<Option value = "English"> French </option>
</Select>
<Select name = "s2">
<Option >== select ==</option>
</Select>
</Form>
<! -- By sundful ending -->
</BODY>
</HTML>