Does anybody know how to imprint someone's IP Address when receiving email through Able Commerce?
Thanks'
Edward
IP Address when receiving email through Able Commerce?
-
- Lieutenant, Jr. Grade (LT JG)
- Posts: 47
- Joined: Tue Nov 11, 2008 10:47 am
- Location: Los Angeles
Re: IP Address when receiving email through Able Commerce?
Try following code to find IP address.
Code: Select all
string ipAddress = Request.ServerVariables["REMOTE_ADDR"];
-
- Lieutenant, Jr. Grade (LT JG)
- Posts: 47
- Joined: Tue Nov 11, 2008 10:47 am
- Location: Los Angeles
Re: IP Address when receiving email through Able Commerce?
hi Mazhar,
how about more information like ISP, country/state, time...?
Thanks'
Edward

how about more information like ISP, country/state, time...?
Thanks'
Edward


Re: IP Address when receiving email through Able Commerce?
Other information could be achieved via some GEO IP service. I have posted a sample in following thread
viewtopic.php?f=47&t=10870
You can extract zip file available in that thread and place GeoLocationHelper in your app code. Then when sending Email you can first get customer IP with trick discussed above and then make a call to
viewtopic.php?f=47&t=10870
You can extract zip file available in that thread and place GeoLocationHelper in your app code. Then when sending Email you can first get customer IP with trick discussed above and then make a call to
Code: Select all
string ipAddress = Request.ServerVariables["REMOTE_ADDR"];
string geoIpInfo = GeoLocationHelper.FindLocationByIP(ipAddress);
//finally you can put some code to add this geoIpInfo string to Email body.