首页 > 编程 > ASP > 正文

asp加密解密函数decrypt

2020-07-27 13:02:10
字体:
来源:转载
供稿:网友
加密与解密函数
<%function decrypt(dcode) 
dim texts
dim i
for i=1 to len(dcode)
texts=texts & chr(asc(mid(dcode,i,2))-i)
next
decrypt=texts
end function
function encrypt(ecode)
Dim texts
dim i
for i=1 to len(ecode)
texts=texts & chr(asc(mid(ecode,i,2))+i)
next
encrypt = texts
end function
%>


<%=decrypt(123123)%>
<a href="11111.asp?id=<%=decrypt("sdfasdfs")%>">111111111</a>
<%abc=encrypt(request("id"))%><%=abc%>
发表评论 共有条评论
用户名: 密码:
验证码: 匿名发表