'======================================================
'函数名 urencoding
'作用 : 转换编码
'======================================================
FunctionUrlencoding (DataTateStr)
Dimstrreturn, Si, Thischr, Innercode, Hight8, Low8
strreturn = "
Forsi = 1Tolen (Destr)
Thischr = mid (datalu, si, 1)
Ifabs (ASC (Thischr)) <& hffthen
Strreturn = Strreturn & Thischr
Kalau tidak
InnerCode = ASC (Thischr)
ifinercode <0then
InnerCode = InnerCode+& H1
Endif
hight8 = (innercodeand & hff00)/& hff
Low8 = InnerCodeAnd & HFF
Strreturn = Strreturn & "%" & hex (hight8) & "& hex (low8)
Endif
Berikutnya
Urlencoding = strreturn
Fungsi endfungsi