应该是这样:
arr=split(session("flag"),",")
for i=0 to ubound(arr)
arr(i)="'"&arr(i)&"'"
next
str=""
for j=0 to ubound(arr)
if j=ubound(arr)then
str=str&arr(j)
else
str=str&arr(j)&","
end if
next
session("flag")=str
data=session("flag")
arr=split(session("flag"),",")
for i=1 to ubound(arr)
arr(i)="'"&arr(i)&"'"
next
str=""
for j=1 to ubound(arr)
if j=ubound(arr)then
str=str&arr(j)
else
str=str&arr(j)&","
end if
next
session("flag")=str