<SCRIPT language=javascript>
var groups1=document.pay1.apnumber.options.length
var group1=new Array(groups1)
for (i=0; i<groups1; i++)
group1[i]=new Array()
<%=groupsort()%>
var temp1=document.pay1.svnumber
function redirect(x){
for (m=temp1.options.length-1;m>0;m--)
temp1.options[m]=null
for (i=0;i<group1[x].length;i++){
temp1.options[i+1]=new Option(group1[x][i].text,group1[x][i].value)
}
temp1.options[0].selected=true
}
</SCRIPT><%function groupsort()
set rs = server.createobject("adodb.recordset")
sql="select * from secondreturn order by apnumber asc"
rs.open sql,conn,1,1
i=0
do while not rs.eof
set rss = server.createobject("adodb.recordset")
sqls="select * from secondreturn where apnumber="&rs("apnumber")&" order by svnumber asc"
rss.open sqls,conn,1,1
o=0
do while not rss.eof
Response.Write "group1["&i&"]["&o&"]=new Option("""&rss("svnumber")&""","""&rss("svnumber")&""")"
o=o+1
rss.movenext
loop
rss.close
set rss=nothing
i=i+1
rs.movenext
loop
rs.close
set rs=nothing
end function
%>
我需要groupsort()里面的换行的。但是现在的都连在一起了,我用“/nn”“<br> ”都试了还不行,我需要怎么改这个代码呢?