|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
drop down lists in asp page ideas
i have a page in asp whith a drop down list for countries
after it i have the counties or provinces i would like to load the asp corresponding to this country but i have no idea how to do it so it is on same page and if country does not exist input county manually there is some way by the moment i have included england and us but i would like to have other include files for other countries i post the thread and the code i am using now on this part code i am using now request but is on same page and of course dont work just the idea code:-------------------------------------------------------------------------------- 'if strState = "1" then ' Response.Write " <tr>" & vbNewLine & _ ' " <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""middle"" nowrap><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>"& strReqdState &" State: </font></b></td>" & vbNewLine & _ ' " <td bgColor=""" & strPopUpTableColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><input class=newlogin name=""State"" size=""25"" maxLength=""50"" value=""" ' if strMode <> "Register" then Response.Write(rs("M_STATE")) ' Response.Write """></font></td>" & vbNewLine & _ ' " </tr>" & vbNewLine 'end if if strCountry = "1" then Response.Write " <tr>" & vbNewLine & _ " <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""middle"" nowrap><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>"& strReqdCountry &" Country: </font></b></td>" & vbNewLine & _ " <td bgColor=""" & strPopUpTableColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _ " <select name=""Country"" size=""1"">" & vbNewLine if strMode <> "Register" then Response.Write(" <option selected value=""" & rs("M_COUNTRY") & """>" & ChkString(rs("M_COUNTRY"), "display") & "</option>" & vbNewLine) else Response.Write " <option value=""""></option>" & vbNewLine end if Response.Write " <option value="""">None</option>" & vbNewLine %> <!--#INCLUDE FILE="inc_countrylist.asp"--> <% Response.Write " </select></font></td>" & vbNewLine & _ " </tr>" & vbNewLine end if if strState = "1" then Response.Write " <tr>" & vbNewLine & _ " <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""middle"" nowrap><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>State: </font></b></td>" & vbNewLine & _ " <td bgColor=""" & strPopUpTableColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _ " <select name=""State"" size=""1"">" & vbNewLine if strMode <> "Register" then Response.Write(" <option selected value=""" & rs("M_STATE") & """>" & ChkString(rs("M_STATE"), "display") & "</option>" & vbNewLine) else Response.Write " <option value=""""></option>" & vbNewLine end if ' how can be done inside the page there is a way if trim(Request.Form("Country")) = "USA" then 'when input check here the check for register or add %> <!--#INCLUDE FILE="inc_usstateslist.asp"--> <% end if if trim(Request.Form("Country")) = "United Kingdom" or trim(Request.Form("Country")) = "Ireland" then ' here the ceck for register or add %> <!--#INCLUDE FILE="inc_ukcountylist.asp"--> <% end if Response.Write " </select></font></td>" & vbNewLine & _ " </tr>" & vbNewLine end if -------------------------------------------------------------------------------- http://www.shnforum.com/forum/topic...301&whichpage=3 thanks for help soler ramon@soler.com |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > drop down lists in asp page ideas |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|