tags:

views:

17

answers:

2

Hi,

Some time ago I developed a multilingual website and now they have asked me that the website should load the language depending on the visitor's IP address. They are going to provide me with an IP address list of different countries.

For example. If an italian visitor loads the website, the website should load www.mydomain.com/it

If the IP is not recognised, the website should load www.mydomain.com

How can I achieve this?

Thanks in advance.

Regards

A: 

I suggest you to try out geo-location service from IP2Location.com.

It is IP address detection and redirect your web visitor based from the geographical location.

I have testing out my Web application by using this IP2location and the data is accurate for helping me to redirect my visitor to correct language site.

It's just similar function to what Google is doing right now.

SuperRomia
A: 

I found a solution and it worked perfectly for me.

I found a site which provides a database table with all the necessary ips and locations. The site can be found at:

http://www.ip2nation.com/

You can download both the sql dump and the php code sample from there.

Chris

related questions