In ASP.net, how would I obtain a visitor's host name instead of just the ip address?
In other words, to get something like this (canonical name):
ool-752652g1.dyn.optonline.net
Instead of this:
64.135.87.300
Printable View
In ASP.net, how would I obtain a visitor's host name instead of just the ip address?
In other words, to get something like this (canonical name):
ool-752652g1.dyn.optonline.net
Instead of this:
64.135.87.300
WOuldn't you retrieve the IP and then pass it to a function in .NET that would resolve the IP into a host name???
Woka
If that is the case, do you know what function that would be or where on a website it can be found?
Try searching this form for resolve IP address, or even better, search the General VB section.
Woka
strHost = System.Net.Dns.GetHostByAddress(YourIP).HostName;