Hi,
I am using classic asp for a project.
A form with two dropdown (state and city) select and other text inputs.
I want to populate the second dropdown from database (using storeprocedure) on changing the value of first dropdown.
I am calling form.Submit() on change of state dropdown. this call populating the city dropdown by using the Request.Form("State").
But this form.Submit() call is clearing all the text inputs value.
I want to create this kind of dependent dropdown that should not clear the input text value.
Help me to achieve this.
Thanking you,
AGM Raja
I am using classic asp for a project.
A form with two dropdown (state and city) select and other text inputs.
I want to populate the second dropdown from database (using storeprocedure) on changing the value of first dropdown.
I am calling form.Submit() on change of state dropdown. this call populating the city dropdown by using the Request.Form("State").
But this form.Submit() call is clearing all the text inputs value.
I want to create this kind of dependent dropdown that should not clear the input text value.
Help me to achieve this.
<select name="State" onChange="this.form.action = '<%=Request.ServerVariables("Script_Name")%>'; this.form.submit();"> <option <%if Trim(Request.Form("EventState"))="" then Response.Write "selected" end if%> value=""> </option> <option <%if Trim(Request.Form("EventState"))="AL" then Response.Write "selected" end if%> value="AL">Alabama</option> <option <%if Trim(Request.Form("EventState"))="AZ" then Response.Write "selected" end if%> value="AZ">Arizona</option></select>Thanking you,
AGM Raja