Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to retrieve IP address 3

Status
Not open for further replies.

vatawna

Programmer
Feb 24, 2004
67
US
Does anyone know how to retrieve the IP address of the computer accessing my website?

Thanks.
 
request.userhostaddress

That's all there is to it.
 
Thanks, evaleah. If 2 computers within the same company or domain access the website, UserHostAddress shows only 1 host IP address, but not 2 computer IP addresses. Do you know how to show the individual computer IP, but not the host IP?

Thanks.
 
A NAT-based firewall will hide the addresses inside it's protected area, so all you get is the firewall address and not the address of the individual computers.

Chip H.


____________________________________________________________________
If you want to get the best response to a question, please read FAQ222-2244 first
 
this is also what happens when the clients use a proxy

what you want is the network adapted MAC address, but AFAIK this cannot be retrieved

--------------------------
"two wrongs don't make a right, but three lefts do" - the unknown sage
 
From Host: " & Request.ServerVariables("REMOTE_HOST")

will give you LAN address that your IIS sees.
I have VPN'd into my network from home, used as above and it returned 192.168.98.100 and when at work computer, 192.168.28.101

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top