Code:
Iname = Ucase(Trim(Request.Form.Item("ChatName")))
If Instr(1,Iname,"GOD",1) OR Instr(1,Iname,"DAMN",1) OR Instr(1,Iname,"SHIT",1) _
OR Instr(1,Iname,"FUCK",1) OR Instr(1,Iname,"BITCH",1) OR Instr(1,Iname,"SUCK",1) _
OR Instr(1,Iname,"BASTARD",1) OR Instr(1,Iname,"PISS",1) OR Instr(1,Iname,"JESUS",1) _
OR Instr(1,Iname,"PRICK",1) OR Instr(1,Iname,"DICK",1) OR Instr(1,Iname,"CRAP",1) _
OR Instr(1,Iname,"PEE",1) OR Instr(1,Iname,"MOTHERF",1) OR Instr(1,Iname,"CUNT",1) _
OR Instr(1,Iname,"PUSSY",1) OR Instr(1,Iname,"TWAT",1) OR Instr(1,Iname,"PUBIC",1) _
Then
Session.Abandon
Response.Cookies("Redirect") = "<FONT COLOR=RED>You can't use those words in here! Go wash your mouth out with soap.</FONT>"
Response.Redirect("name.asp")
End If
There are a few more things to do like make sure the response cookie gets cleared.