So, yesterday, I received an odd email through one of my various email forms. Unfortunately, the person used a fake email address, and a fake name, so I couldn't really get a glimpse into where on earth this email had come from. So I decided to add something to the mail script to make it a bit more user-friendly. User-friendly for me. Not others.
So what I did was this. I added a key to the mail form that sends along a person's IP address when they submit something to me. It's a hidden form field, and the IP address can be spoofed through proxies, etc, but it adds another element of info to my pages, and if a person is not wiley enough to use a proxy, then I'd have the extra data. I figured I would just look up the IP on a website like DNSStuff.com.
What I found, however, is that there's a website called hostip.info, which is a database that contains geo-coordinates for various IP addresses, and includes Country, and City/State data as well. This website also utilizes the Google Map API to show a graphical representation of where things are in the world wide web.
I figured I'd do the same thing. Why not, after all? If I can, and it's fun, why not? So I figured out a way to grab the data from hostip.info, and feed it to the Google Map. The result is that any email I get now sends along the IP of the person sending it, and I need only click on the link that displays their data to me. You can find this handy-dandy tool here: Google IP Mapper.