请帮忙看一下,Array1值中如果带有",",后台怎么接收?
在页面a.asp中,array的参数是一条sql语句:
Dim i
Dim Array1(3)
<form name="frmInput" method="post" action="b.asp">
<% For i=0 to 2 %>
<input type="hidden" name="Array1" value="insert into(name,ok)values('张三','好') " />
<% Next %>
</form>
在页面b.asp中:
<%
Dim N
Dim Array1
'// 获取这个属组
Array1=Request.Form("Array1")
Array1=Split(Array1, ",") //这里就有问题了,不能完整完取值
N=UBound(Array1)
Dim i
For i=0 to N-1
Response.Write Array1(i)&"</p>"
Next
%>
------解决方案--------------------通过item获取,不要split
Dim N
Dim Array1
N=Request.Form("Array1").count''''''''''''''''
for i=1 to N''''''''''''''''
response.Write Request.form("Array1").item(i)&"<br/>"''''''''''''
next