asp 过滤非法字符函数分享
发布时间:2023-05-31 13:46:07 所属栏目:Asp教程 来源:
导读:过滤非法字符
<%
Function cutbadchar(str)
badstr="不|文|明|字|符|列|表|格|式"
badword=split(badstr,"|")
For i=0 to Ubound(badword)
If instr(str,badword(i)) > 0 then
str=Repl
<%
Function cutbadchar(str)
badstr="不|文|明|字|符|列|表|格|式"
badword=split(badstr,"|")
For i=0 to Ubound(badword)
If instr(str,badword(i)) > 0 then
str=Repl
过滤非法字符 <% Function cutbadchar(str) badstr="不|文|明|字|符|列|表|格|式" badword=split(badstr,"|") For i=0 to Ubound(badword) If instr(str,badword(i)) > 0 then str=Replace(str,badword(i),"***") End If Next cutbadchar=str End Function Response.Write cutbadchar("中国不阿斗发射点发明") %> (编辑:聊城站长网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
推荐文章
站长推荐