Ban user based on their IP address

Submitted by:Tim Kelly

Date added:16 February, 2012

Category:ASP

ASP code to ban user based on their IP address

Tags: ban user

Code Snippet:

<% 
Dim bannedIP = Request.ServerVariables("REMOTE_ADDR")
'this is the IP to ban here
If bannedIP = "100.100.100.100" Then
Response.Redirect ("banned.php")
End If
%>
 
 

Comments