users IP Address





4
Date Submitted Fri. Mar. 3rd, 2006 8:16 AM
Revision 1 of 1
Syntax Master dannyboy
Tags ASP | IP | ServerVariables
Comments 0 comments
Using ASP or Active Server Pages it is actually quite easy to retrieve a users IP Address

<%
Dim UserIPAddress
UserIPAddress = Request.ServerVariables("HTTP_X_FORWARDED_FOR")
If UserIPAddress = "" Then
  sIPAddress = Request.ServerVariables("REMOTE_ADDR")
End If
%>
 

Comments

There are currently no comments for this snippet.

Voting