asp+javescirpt 如何作三级分类下拉选择菜单?
我有一个asp+javescript 的代码,当用下拉菜单选择某一个省份以后 二级下拉菜单 会出现 相应的 城市名称 供选择, 现在我我想详细到 三级即 分类到 城镇.
请问该如何写这样的代码?
数据库又该如何设计呢?
最好能提供源代码.(我现在用的是网上某商城的代码.)
部分代码如下:
<tr bgcolor=ffffff>
<td align= "right "> 所在城市: </td>
<td>
<select size= "1 " class= "wenbenkuang " name= "wq_province " onChange=chsel()>
<option value= "xxx " selected> 请选择省份…… </option>
<%dim tmpShengid
tmpShengid=0
set rs_s=server.createobject( "adodb.recordset ")
sql= "select * from qiongfu_province order by shengorder "
rs_s.open sql,conn,1,1
while not rs_s.eof
if rs( "szsheng ")=rs_s( "ShengNo ") then
tmpShengid=rs_s( "id ")
%>
<option value= " <%=rs_s( "ShengNo ")%> " selected > <%=trim(rs_s( "ShengName "))%> </option>
<%
else
%>
<option value= " <%=rs_s( "ShengNo ")%> " > <%=trim(rs_s( "ShengName "))%> </option>
<%
end if
rs_s.movenext
wend
rs_s.close
set rs_s=nothing
%>
</select>
<select size= "1 " class= "wenbenkuang " name= "wq_city ">
<%
set rs_s=server.createobject( "adodb.recordset ")
sql= "select * from qiongfu_city where shengid= "&tmpShengid& " order by shiorder "
rs_s.open sql,conn,1,1
while not rs_s.eof
%>
<option value= " <%=rs_s( "ShiNo ")%> " > <%=trim(rs_s( "ShiName "))%> </option>
<%
rs_s.movenext
wend
rs_s.close
set rs_s=nothing
%>
</select>
<font color= "#FF0000 "> ** </font> </td>
</tr>
<s