📄 char.asp
字号:
strInputEntry = Replace(strInputEntry, "mOno", "mono", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "mono", "mono", 1, -1, 1)
formatInput = strInputEntry
End Function
''''''''''''''''''''''''''''''''''''''''''
Function formatLink(ByVal strInputEntry)
strInputEntry = Replace(strInputEntry, "document.cookie", ".", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "javascript:", "javascript ", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "vbscript:", "vbscript ", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "javascript :", "javascript ", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "vbscript :", "vbscript ", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "[", "", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "]", "", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "(", "", 1, -1, 1)
strInputEntry = Replace(strInputEntry, ")", "", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "{", "", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "}", "", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "<", "", 1, -1, 1)
strInputEntry = Replace(strInputEntry, ">", "", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "|", "", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "script", "script", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "object", "object", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "applet", "applet", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "embed", "embed", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "document", "document", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "cookie", "cookie", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "event", "event", 1, -1, 1)
strInputEntry = Replace(strInputEntry, "on", "on", 1, -1, 1)
formatLink = strInputEntry
End Function
''''''''''''''''''''''''''''''''''''''''''
function gotTopic(str,strlen)
if str="" then
gotTopic=""
exit function
end if
dim l,t,c, i
str=replace(replace(replace(replace(str," "," "),""",chr(34)),">",">"),"<","<")
l=len(str)
t=0
for i=1 to l
c=Abs(Asc(Mid(str,i,1)))
if c>255 then
t=t+2
else
t=t+1
end if
if t>=strlen then
gotTopic=left(str,i) & "…"
exit for
else
gotTopic=str
end if
next
gotTopic=replace(replace(replace(replace(gotTopic," "," "),chr(34),"""),">",">"),"<","<")
end function
''''''''''''''''''''''''''''''''''''''''''
function IsValidEmail(email)
dim names, name, i, c
IsValidEmail = true
names = Split(email, "@")
if UBound(names) <> 1 then
IsValidEmail = false
exit function
end if
for each name in names
if Len(name) <= 0 then
IsValidEmail = false
exit function
end if
for i = 1 to Len(name)
c = Lcase(Mid(name, i, 1))
if InStr("abcdefghijklmnopqrstuvwxyz_-.", c) <= 0 and not IsNumeric(c) then
IsValidEmail = false
exit function
end if
next
if Left(name, 1) = "." or Right(name, 1) = "." then
IsValidEmail = false
exit function
end if
next
if InStr(names(1), ".") <= 0 then
IsValidEmail = false
exit function
end if
i = Len(names(1)) - InStrRev(names(1), ".")
if i <> 2 and i <> 3 then
IsValidEmail = false
exit function
end if
if InStr(email, "..") > 0 then
IsValidEmail = false
end if
end function
''''''''''''''''''''''''''''''''''''''''''
function strLength(str)
ON ERROR RESUME NEXT
dim WINNT_CHINESE
WINNT_CHINESE = (len("中国")=2)
if WINNT_CHINESE then
dim l,t,c
dim i
l=len(str)
t=l
for i=1 to l
c=asc(mid(str,i,1))
if c<0 then c=c+65536
if c>255 then
t=t+1
end if
next
strLength=t
else
strLength=len(str)
end if
if err.number<>0 then err.clear
end function
''''''''''''''''''''''''''''''''''''''''''
function errorbox(errorstr)
Response.Write "<br><br><br><br><table width=60% border=0 align=center cellpadding=0 cellspacing=0><tr><th height=25><div align=left> 错误信息</div></td></tr><tr><td align=left class=TableBody1><BR> "&errorstr&"<br><br><br> <a href=javascript:history.go(-1);>返回</a><BR><BR></td></tr></table>"
response.end
end function
''''''''''''''''''''''''''''''''''''''''''
function Successbox(Successstr)
Response.Write "<br><br><br><br><table width=60% border=0 align=center cellpadding=0 cellspacing=0><tr><th height=25><div align=left> 成功信息</div></td></tr><tr><td align=left class=TableBody1><BR> "&Successstr&"<br><br><br> <a href=javascript:history.go(-1);>返回</a><BR><BR></td></tr></table>"
response.end
end function
''''''''''''''''''''''''''''''''''''''''''
function fenpage(totalRecs,startRec,url,widthX)
dim zongpage,zhuangtai,showpage,I,I_XX
showpage=3
zhuangtai = "<td Class=TopLighNav width=5><A HREF="&url&"1><B><</B></A></td>"
If totalRecs/sysX(0)<>CInt(totalRecs/sysX(0)) Then
zongpage=Fix(totalRecs/sysX(0))+1
else
zongpage=clng(totalRecs/sysX(0))
end if
I_XX=Clng(startRec)
I = startRec-3
Do While I<I_XX
If I>=1 Then
zhuangtai = zhuangtai & "<td Class=TopLighNav width=5><A HREF="&url&""&I&">"&I&"</A></td>"
End If
I=I+1
loop
I = I_XX
Do While I<=I_XX+3
If I<=zongpage Then
zhuangtai = zhuangtai & "<td Class=TopLighNav width=5><A HREF="&url&""&I&">"&I&"</A></td>"
End If
I=I+1
loop
zhuangtai = zhuangtai & "<td Class=TopLighNav width=5><A HREF="&url&""&zongpage&"><B>></B></A></td>"
%>
<table width="<%=widthX%>" cellspacing=0 cellpadding=0 align=center>
<tr><td align="CENTER" width="150" Class="TableTitle2">共有记录<%=totalRecs%>条|当前第<%=startRec%>页</td>
<td align="right" Class="TableTitle2"><table cellspacing=0 cellpadding=0 align=right class=tableBorder1><tr><%=zhuangtai%></tr></table></td></tr></table>
<%
end function
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -