How to redirect people from different countries to different page

ChatIndia

Community Advocate
Community Support
Messages
1,408
Reaction score
30
Points
48
I want to have a multilingual site. Hindi for Indian's and English for rest of the world. Even I can ask my friends to translate it into Bengali, Gujarati and Marathi. So How can I do this, do you have any idea about it? I want to use IP for it. I know that many people used to change their IP by software's, I also used to do when I'm not in my country or when I want to search something specific from other country but most of the time people don't use it at least for fair sites. So How to do this?
 

Danielx386

Member
Messages
712
Reaction score
9
Points
18
you could do it by .htaccess, but you would need to know all the different ip address for the different countries

Daniel
 

jtwhite

Community Advocate
Community Support
Messages
1,381
Reaction score
30
Points
0
You could use php and search the IP string for a certain pattern. It would be difficult. It would be easier to have like a landing page and have the visitor chose the language.

BTW, according to the Terms of Service agreement:
At this time x10Hosting only supports English, Spanish and French websites on free hosting, these restrictions do not apply to paid hosting. Sites found breaking this rule will be permanently suspended.
 
Last edited:

ChatIndia

Community Advocate
Community Support
Messages
1,408
Reaction score
30
Points
48
You could use php and search the IP string for a certain pattern. It would be difficult. It would be easier to have like a landing page and have the visitor chose the language.

BTW, according to the Terms of Service agreement:

I'm not bound by x10 TOS cause I'm on a paid hosting on another host, hooray
 

stesouthby

New Member
Messages
115
Reaction score
0
Points
0
lol but yer your easiest way would be to have a starter page with there langues and flags you want them to be in just because if you get the wrong ip address you might end up sending an english person to trying to read your site in german lol
 

Smith6612

I ate all of the x10Pizza
Community Support
Messages
6,517
Reaction score
48
Points
48
The main gate (or a Global Page) would be one of the easiest ways to do it where people can choose where they're from and have the site remember the selection via a cookie. If you want to be crafty and know a bit about GeoIP data, you can in fact use code which will look at a person's location via GeoIP. Then there's the route of listing down possible hostnames for ISPs/IP blocks.

What might be the easiest way of doing this is by using the information the browser sends. The main headers that every browser sends on connecting will give you the user's language, and in cases where there is more than one country for a language, their location (like EN-US and EN-UK). You can have your code look directly at that information as it's typically very reliable. GeoIP is a better route though given your GeoIP provider/methods can remain up to date!
 
Last edited:
Top