Auto Redirect based on IP?
jeremyr - November 5, 2009 - 21:43
| Project: | Domain GeoLocalization |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
Is it possible to configure this module to auto-detect the user's location from the IP and then push that user to the nearest (Geolocation enabled) domain?
This would save the step of having to enter in a zip code. What do others think of this? I'm willing to help develop this feature however I'm not as good as I thought in module development.
Thanks!

#1
Since this adds extra functionality not required for most sites I think this should be a bridge module between Domain Geolocalization and another module that provides ip based detection. So far http://drupal.org/project/geosniper seems to provide all the data needed but has added complexity. Ideally there would be a module like http://drupal.org/project/geoip that provides the data based on user's ip address and the bridge module performs redirects based on ip data/domain geolocalization data.
#2
I've been looking into ways it could theoretically be done. It seems that geosniper does really well at providing the IP details however it's limited to 25 queries a day, not so good on high-traffic sites.
The other I was looking at was a database that you can either get a "lite" database that is free or pay for the slightly more accurate data source and pay a subscription to MaxMind.com. Really, maxmind might be the way to go because it offers the free database, but maybe there is a way to choose the data source you want to use.
The way I've thought it out is that the IP could be looked up on first visit and then redirected upon finding the nearest domain. Not sure where this would have to happen.