sladmin
09-05-2007, 02:34 PM
Hey,
I'm currently trying to block certain usernames that try and sign up to my website. Obviously usernames such as 'administrator' and 'admin' are not allowed. :ninja:
I wrote this IF statement but the only problem with it is that it only blocks one word. I can't seem to be able to use more than one word for one statement. Of course I could use multiple statements but that would just take ages and would slow down the loading times of the webpage.
<% IF request.Form("Username") = "admin" then
session("UsernameBlock") = "That username is not allowed" & Response.redirect("/register/signup.asp")
End IF
%>I could do this...
<% IF request.Form("Username") = "admin","administrator" then
session("UsernameBlock") = "That username is not allowed" & Response.redirect("/register/signup.asp")
End IF
%>Any ideas how I could use multiple usernames?
Thanks,
I'm currently trying to block certain usernames that try and sign up to my website. Obviously usernames such as 'administrator' and 'admin' are not allowed. :ninja:
I wrote this IF statement but the only problem with it is that it only blocks one word. I can't seem to be able to use more than one word for one statement. Of course I could use multiple statements but that would just take ages and would slow down the loading times of the webpage.
<% IF request.Form("Username") = "admin" then
session("UsernameBlock") = "That username is not allowed" & Response.redirect("/register/signup.asp")
End IF
%>I could do this...
<% IF request.Form("Username") = "admin","administrator" then
session("UsernameBlock") = "That username is not allowed" & Response.redirect("/register/signup.asp")
End IF
%>Any ideas how I could use multiple usernames?
Thanks,