Function thutucdequycombo(idc,i) Set objConn = Server.CreateObject("ADODB.Connection") objConn.ConnectionString = strConnection objConn.Open Set rs = Server.CreateObject("ADODB.RecordSet") rs.Open "SELECT * From rtm_area Where parent_aid = "&idc ,objconn, 1, 3 k = rs.recordcount j=1 while not rs.eof IF rs("parent_aid") <> idc Then Option_select_03 = Option_select_03 & "<option value=""" & rs("aid") & """>" & rs("name") & "</option>" Else Option_select_03 = Option_select_03 & "<option value=""" & rs("aid") & """> " & rs("name") & "</option>" End IF thutucdequycombo rs("aid"),rs("parent_aid") ' Goi lai chinh no - dequy rs.movenext j=j+1 'response.write" " wend End Function thutucdequycombo 0,0
aid: int name: nvachar 50 parent_id: int
Leve1 1-1 1-2 Lever2 2-1 2-2 2-3 .......
<input>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)