MyBB Community Forums
Detect language from IP address - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: Development (https://community.mybb.com/forum-161.html)
+--- Forum: Suggestions and Feedback (https://community.mybb.com/forum-199.html)
+--- Thread: Detect language from IP address (/thread-220881.html)

Pages: 1 2


Detect language from IP address - MangaD - 2018-11-29

It is not very user friendly to a person who doesn't know English to come to a site that appears to be English and have to scroll down to find out they can switch language. It would be great if MyBB could auto-detect where this person is from and automatically switch language accordingly.


RE: Detect language from IP address - Serpius - 2018-11-29

(2018-11-29, 01:28 PM)MangaD Wrote: It is not very user friendly to a person who doesn't know English to come to a site that appears to be English and have to scroll down to find out they can switch language. It would be great if MyBB could auto-detect where this person is from and automatically switch language accordingly.

My suggestion is to re-create the login page to accommodate the different languages. 

The page can contain options such as:

Log In English - Select This
Log In Chinese - Select This
Log In Other Language (admin will determine the language here) - Select This

You can insert as many languages you want, but you MUST install any new languages from this FORUM to make everything work properly.


RE: Detect language from IP address - MangaD - 2018-11-29

@Serpius What about guests and people who are registering?


RE: Detect language from IP address - laie_techie - 2018-11-29

I'd much rather use the "Accept-Language" http header than trying to translate an IP to a language.

I am from the United States, but visit Japan on a business trip. While I understand some spoken Japanese, I can't read Kanji.
A niece from Brazil visits my wife and I in the USA, but she doesn't' understand English.
Someone is using an open vpn in a different country to bypass their government's country-wide firewall.
How many people live in the USA who don't speak English?
In Brazil I met a man who moved their from Japan just a week prior and spoke zero Portuguese.

Users should configure their browsers to indicate their preferred language.

Another suggestion would be include a language selector towards the top of the page instead of scrolling all the way down.


RE: Detect language from IP address - Serpius - 2018-11-29

(2018-11-29, 07:25 PM)laie_techie Wrote: I'd much rather use the "Accept-Language" http header than trying to translate an IP to a language.

I am from the United States, but visit Japan on a business trip. While I understand some spoken Japanese, I can't read Kanji.
A niece from Brazil visits my wife and I in the USA, but she doesn't' understand English.
Someone is using an open vpn in a different country to bypass their government's country-wide firewall.
How many people live in the USA who don't speak English?
In Brazil I met a man who moved their from Japan just a week prior and spoke zero Portuguese.

Users should configure their browsers to indicate their preferred language.

Another suggestion would be include a language selector towards the top of the page instead of scrolling all the way down.

That's pretty much what I suggested in post #2.


RE: Detect language from IP address - Lopot - 2018-11-29

Would be a good feature but only if it can always detect right country and still show English option


RE: Detect language from IP address - linguist - 2018-11-29

(2018-11-29, 07:25 PM)laie_techie Wrote: I'd much rather use the "Accept-Language" http header than trying to translate an IP to a language.

I am from the United States, but visit Japan on a business trip. While I understand some spoken Japanese, I can't read Kanji.
A niece from Brazil visits my wife and I in the USA, but she doesn't' understand English.
Someone is using an open vpn in a different country to bypass their government's country-wide firewall.
How many people live in the USA who don't speak English?
In Brazil I met a man who moved their from Japan just a week prior and spoke zero Portuguese.

Users should configure their browsers to indicate their preferred language.

Another suggestion would be include a language selector towards the top of the page instead of scrolling all the way down.

This.
Plus: there's places (countries) with more than one language. IP from Brussels: Do you serve French or Dutch content? IP from Singapore: Do you serve Malay, Chinese, or Hindi content? Don't override peoples' preferences based on their IP.


RE: Detect language from IP address - MangaD - 2018-12-02

@laie_techie Thank you very much for your suggestion. I don't know much about the "Accept-Language" http header. Does the browser send this header to the website?

@Lopot There's an option for registered members to choose their default language. I am only concerned with guests. I think not getting it right all the time is not a big problem. To exemplify, my forum has English and Chinese languages only. It would be hard for a non-Chinese guest to get the Chinese language I think.


RE: Detect language from IP address - Omar G. - 2018-12-03

For guests, rather that attempting to guess their language, a better placement or redesign of the language selector would be better, something that is more UX/UI friendly.


RE: Detect language from IP address - laie_techie - 2018-12-03

(2018-12-02, 05:15 PM)MangaD Wrote: @laie_techie Thank you very much for your suggestion. I don't know much about the "Accept-Language" http header. Does the browser send this header to the website?

The Accept-Language http header is constructed by the browser based on the user's configuration.