url解码aa aa

lein42 2007-02-26 10:55:31
<a href="%E6%8C%A8%E6%89%93">aaaaaaa </a>
<a href="挨打">aaaaaaa </a>
%E6%8C%A8%E6%89%93、挨打是两种不同的编码方法,有什么不同;
如何解码:挨打?
...全文
990 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
lein42 2007-02-26
  • 打赏
  • 举报
回复
汗哦,呵呵,是个办法,不过我是想要vbs的。
谢谢~
zhangjincheng88 2007-02-26
  • 打赏
  • 举报
回复
mark
hbjmdx008 2007-02-26
  • 打赏
  • 举报
回复
楼上正解。
Taciterry 2007-02-26
  • 打赏
  • 举报
回复
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
</head>

<body>
<div id="generator" style="display:none;"></div>
<input type="text" id="inpValue" /><input type="button" onclick="generator.innerHTML=inpValue.value;outValue.value=generator.innerText" value="Go" />
<input type="text" disabled="disabled" id="outValue" />
</body>
</html>


这个怎样~
leinchu 2007-02-26
  • 打赏
  • 举报
回复
自己来解答:
str0="这是一个utf-8字符串!"
function reg_arr(reg_str,str,ml)
Set re = New RegExp
re.Pattern = reg_str
re.Global = True
re.IgnoreCase = True
re.MultiLine = True
set m=re.execute(str)
dim rtn
dim tmp
redim rtn(m.count-1)
i=0
for each mt in m
mv=mt.value
redim tmp(ml)
for k=1 to ml
par="$"&k
tmp(k-1)=re.replace(mv,par)
next
rtn(i)=tmp
i=i+1
next
reg_arr=rtn
end function
function utf8code2gb(str)
strs=reg_arr("&#(\d+);",str,1)
for i=0 to ubound(strs)
str=replace(str,"&#"&strs(i)(0)&";",chrw(strs(i)(0)))
next
utf8code2gb=str
end function
msgbox(utf8code2gb(str0))

%E6%8C%A8%E6%89%93用的是ascii编码的16进制
挨打是unicode编码

28,391

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧