这样的字符串如何进行替换呢
a="m1,s;k3,1p;sk,we32;aaa=abcde+m1+kfj+k3+sadfgh+sk+dkffgg"
替换成
a="abcdeskfj1psadfghwe32dkffgg"
[解决办法]
a="m1,s;k3,1p;sk,we32;aaa=abcde+m1+kfj+k3+sadfgh+sk+dkffgg"
arr=split(a,"aaa=")
kvs=split(arr(0),";")
for i=0 to ubound(kvs)
if trim(kvs(i))<>"" then
kv=split(kvs(i),",")
if ubound(kv)=1 then arr(1)=replace(arr(1),"+"&kv(0)&"+",kv(1))
end if
next
a=arr(1)
response.write a