function2.asp

来自「admin/admin.asp是WAP的后台管理登陆页面」· ASP 代码 · 共 30 行

ASP
30
字号
<%
function encodestr(str)
	str=trim(str)
	if IsNull(str) then exit function
	str=replace(str,"&","&amp;")
	str=replace(str,"<","&lt;")
	str=replace(str,">","&gt;")
	str=replace(str,"$","$$")
        str=replace(str,Chr(13),"<br/>")
        str=replace(str,"@/","<br/>")
	str=replace(str,"'","&#39;")
	Set re=new RegExp
	re.IgnoreCase =true
	re.Global=True
	re.pattern="(\[img\])(.[^\[]*)(\[\/img\])"
	str= re.Replace(str,"<a href=""admin/up/upfile/$2""><img src=""admin/up/small/$2"" alt=''/></a>")
	re.pattern="(\[url\])(.[^\[]*)(\[\/url\])"
	str= re.Replace(str,"<a href=""$2"" >$2</a>")
	re.pattern="(\[f=(.[^\]]*)\])"
	str= re.Replace(str,"<img src=""face/$2.gif""/>")
	re.pattern="(\[url=(.[^\]]*)\])(.[^\[]*)(\[\/url\])"
	str= re.Replace(str,"<a href=""$2"" >$3</a>")
	re.Pattern = "^(http://[A-Za-z0-9\./=\?%\-&_~`@':+!]+)"
	str = re.Replace(str,"<a href=""$1"">$1</a>")
	re.pattern="(\[no\])(.[^\[]*)(\[\/no\])"
	str= re.Replace(str,"<a href=""wtai://wp/mc;$2"" >$2</a>")
	set re=Nothing
	encodestr=str
end function
%>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?