BenningtonCS / Telescope-2014

4 stars 0 forks source link

get location and lat long from IP #35

Open edaniszewski opened 10 years ago

edaniszewski commented 10 years ago

add functionality that will attempt to auto-get the user's location and lat/long, and if it can't prompt the user or alert the user that it should be updated manually.

edaniszewski commented 10 years ago

maybe auto find on initial install (have script as part of installer that asks if found location is the right location), and include a button or feature somewhere that allows users to manually change the IP if needed

edaniszewski commented 10 years ago

commit d00e6584f3d5817b461e61bfe77750afd456187c

edaniszewski commented 10 years ago

I believe this is finished, and just needs a code check, @Kgespada or @vpascow

acencini commented 10 years ago

i believe there is an API for doing this - doing via script seems scary

bgwalter commented 10 years ago

Should we see if there's a way to do this with the API? In the meantime, I checked this over and tested it out and it all works fine

acencini commented 10 years ago

http://ipinfodb.com/ip_location_api.php

you'd probably need to use a C web service client generator (http://www.cs.fsu.edu/~engelen/soap.html) - i used this in 2008 for a commercial product at verdiem and while it's hairy, it's known good

edaniszewski commented 9 years ago

since deciding to move the trivial stuff to python:

http://pythonhosted.org/python-geoip/ http://stackoverflow.com/questions/2543018/what-python-libraries-can-tell-me-approximate-location-and-time-zone-given-an-ip