javascript 传递 '-' 时出错 换成 '&' ok

function changeid(){
var id=document.id1.id11.value
id8=id.split("&")
var id1=id8[0]
var id2=id8[1]
alert(id1)
alert(id2)
}

 

<select name="id11" onChange="changeid()" style="width:100px;">  
               <%
                 set rs1=server.createobject("adodb.recordset")
                 rs1.open"select * from basic_Info where auto_id in(select distinct auto_id from basic_info where model='"&rs("model")&"')",check_conn,1,3
                 do while not rs1.eof
               %>
                  <option value="<%=rs("auto_id")%>&<%=rs1("auto_id")%>"><%=rs1("Auto_Trim")%></option>
                  <%
                  rs1.movenext
                  loop
                  rs1.close
                  set rs1=nothing
                  %>
               </select>

posted @ 2009-07-12 16:35  y0umer  阅读(115)  评论(0编辑  收藏  举报