![]() |
Geo IP Question...
How easy / simple / complicated would it be to do the following...
Surfer clicks text link: If surfers in Europe, they see Europe page If surfers in America, they see USA page If surfer is 'somewhere else' the see the 'somewhere else' page' Simple enough on paper but how simple to set up and how would I go about it? What would I need to do to make this happen, or is it a big complicated expensive deal? Doesn't need to be TOTALLY accurate... Just pretty much so... Just looking for some theoretical information.. Thanks :) |
http://www.maxmind.com/app/ip-location
They have a free version of their location DB if you want free. Just find the code example of your choice on their site and you're off and running. |
Thanks, will look into them :)
|
GrouchAdmin's "How to do GeoIP the proper way with minimal overhead" example
MaxMind's mod_geoip directly inserted into your webserver would be the easiest for external/programmable GeoIP support. It'd make more sense to check the browser's language(s) of choice, than force a user of a region into a language they don't want. Let Apache handle the language, itself, then just display the runtime code (if that's what you want to do) independently with mod_geoip. First, setup your supported languages, and priority in Apache: Code:
AddLanguage en .en Code:
LanguagePriority en fr es de Now, GeoIP's database for the country name database part, which almost mimmics the above, but uses a different format, ISO3166: Here's some tiny little throwaway GeoIP code. It displays those tiny flags in my sig. It has very little overhead with mod_geoip, marginal with the runtime PHP library. This is an old version without eTags (caching) support. It'd be smarter to cache these into RAM than to continually read them from the disk, if you have the choice. You may use this code, if you want. Code:
<?php |
Hey Grouch, Thanks for the reply, however it may be more technical than I need or (truthfully) understand...
Here's what I want in a simpler way of explaining it... The text link that gets clicked, is a link to a dating site... Not an AFF or similar, ie a porn type site, with phony profiles etc... Im talking a REAL DATING SITE. Mainstream... Match.com or similar... My Idea was that if they were in Europe and clicked, they would get a European based dating site... If the surfer was in America, they get a USA based dating site... And, as an afterthought, if they were somewhere else ie China... I could just throw them somewhere else... Its NOT about languages. Its just about getting a European person to a euro landing page and an American to a USA landing page... Thats all really... |
Quote:
either. |
Yea.. this is something I have been looking at also..
how is the load on the server.. do you normally use the php mod, or perl, or what? Load on the server is not much? |
Quote:
|
All times are GMT -7. The time now is 01:54 PM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123