Jump to content

Language selection

Featured Replies

Posted

Why is the language not selected based upon browser settings, this is nothing new its all ready a few years old. When you select language based upon browser settings you can do fun stuff like Articles in different languages and only show what is available or show everything but where the settings show native language first. This can be used for articles, download, gallery and blogs you only need to provide additional fields where you can put in the translation so the system knows what language it is.

  • Author

It does not work in Chrome i tried it, also IE 11 it does not work and in FireFox 34.0.5 it still does not work. Would be a great improvement if i could get it to work.

Please provide your site URL where I can test it. Also, make sure that you have activated two or more languages

  • Author

Your welcome to try it at http://www.jeroenpil.com The languages are Dutch and English if you are trying Dutch the menu word Calendar reads as Kalender that's the only word that is translated for testing this feature. I can switch between English and Dutch without any errors but it will not select the correct language based on browser and i made sure i was not logged in.

We preselect a language based on your HTTP_ACCEPT_LANGUAGE browser header.  If your browser doesn't send one or sends one that doesn't match an installed language, the default language is used.

  • Author

I have tried with Chrome, Firefox and IE11 they all do the same thing that is use default language only. When i go to this site http://www.albertcasadessus.com/wp-content/uploads/getlang_example.php i get the following "Your browser preferred language is: nl" this is correct my default language in the browsers is NL. So why is IPB4 not sending the correct language trough.

Are you visiting as a guest or a user?  Once you have registered, your user account preference is used.

  • Author

Are you visiting as a guest or a user?  Once you have registered, your user account preference is used.

​As guest on my default browser and Firefox and IE11 i haven't logged in at all.

​As guest on my default browser and Firefox and IE11 i haven't logged in at all.

​Ok, can you enable Nederlands as default language in your community? I try to test it again

  • Author

​Ok, can you enable Nederlands as default language in your community? I try to test it again

​Done

 

Ok, I have same problem. But autodetect in my Beta 4b community works fine.

Try to re-install your community. If this problem is not solved, submit a bug in IPS4 Bug Tracker.

2015-01-06 23-33-25 Скриншот экрана.png

Yes, your installation is broken. Re-install IPS4. Font Awesome not displayed. I think it's not only one problem  :)

  • Author

Well all ready installed it again going to download the script again and also run what is needed to run IPB and start from scratch.

  • Author

I have run the script to check if the server can run IPB 4 and i get this:

 

You are ready to install IPS Community Suite 4.0, but not IP.Nexus.
 

IP.Nexus i do not use so that does not matter, the MySQL i get a warning that the best version is 5.6.0 but that is not yet in a package so i need to wait for that one. All the other once i get a green light.

I am going to run the installer in the weekend so i can look what's happening.

Add this php script in your forum root directory and then visit it in your browser

 

<?php

$language = null;

        if( isset( $_SERVER['HTTP_ACCEPT_LANGUAGE'] ) )
        {
            if( mb_strpos( $_SERVER['HTTP_ACCEPT_LANGUAGE'], ',' ) )
            {
                $language    = explode( ',', $_SERVER['HTTP_ACCEPT_LANGUAGE'] );
                
                $language    = $language[0];
            }
            else
            {
                $language    = $_SERVER['HTTP_ACCEPT_LANGUAGE'];
            }
        }

var_dump( $language );

 

What do you get?

  • Author

I get the following response back:

string(2) "nl"

This seems correct in my eye's

I believe I see what the problem would be caused by and have just committed a fix.

  • Author

I believe I see what the problem would be caused by and have just committed a fix.

Brandon with IPB4 beta 5 this problem is now fixed for me.

Thanks for confirming

  • 2 years later...

Hello @bfarber

 

I would like to disable this option

"We preselect a language based on your HTTP_ACCEPT_LANGUAGE browser header.  If your browser doesn't send one or sends one that doesn't match an installed language, the default language is used."

I have already installed a free plugin that makes/forces the guests  see the forum in the default selected language  and

i also want all membergroups to also bypass this feature.

explanation why - in greece many people have english browsers because this makes the usage much easier - greek words are long. 

  having english browser does not necessarily mean  they should be reading the forum in english. 

our default member language is x (greek) not english, so  I would like the default to really mean default , even if the user does have other languages in his browser, on his pc, or wherever. 

do i need to seek another plugin for that or is there an option for this to happen ?

I think its good to have all these technical features, but there should be an option for admin to choose if he really needs to use them. 

maybe up to now something has changed!?

 

14 minutes ago, MeMaBlue said:

Hello @bfarber

 

I would like to disable this option

"We preselect a language based on your HTTP_ACCEPT_LANGUAGE browser header.  If your browser doesn't send one or sends one that doesn't match an installed language, the default language is used."

I have already installed a free plugin that makes/forces the guests  see the forum in the default selected language  and

i also want all membergroups to also bypass this feature.

explanation why - in greece many people have english browsers because this makes the usage much easier - greek words are long. 

  having english browser does not necessarily mean  they should be reading the forum in english. 

our default member language is x (greek) not english, so  I would like the default to really mean default , even if the user does have other languages in his browser, on his pc, or wherever. 

do i need to seek another plugin for that or is there an option for this to happen ?

I think its good to have all these technical features, but there should be an option for admin to choose if he really needs to use them. 

maybe up to now something has changed!?

 

You would need a plugin I'm afraid.

  • 5 months later...
On 4/20/2017 at 2:27 PM, MeMaBlue said:

Hello @bfarber

 

I would like to disable this option

"We preselect a language based on your HTTP_ACCEPT_LANGUAGE browser header.  If your browser doesn't send one or sends one that doesn't match an installed language, the default language is used."

I have already installed a free plugin that makes/forces the guests  see the forum in the default selected language  and

i also want all membergroups to also bypass this feature.

explanation why - in greece many people have english browsers because this makes the usage much easier - greek words are long. 

  having english browser does not necessarily mean  they should be reading the forum in english. 

our default member language is x (greek) not english, so  I would like the default to really mean default , even if the user does have other languages in his browser, on his pc, or wherever. 

do i need to seek another plugin for that or is there an option for this to happen ?

I think its good to have all these technical features, but there should be an option for admin to choose if he really needs to use them. 

maybe up to now something has changed!?

 

Did u find some solution to turn that detection off ? Same problem here, everyone uses eng browser locale but forum language should be something different.

You could use 

 

Yes i am using it too!!works just fine!!!

Archived

This topic is now archived and is closed to further replies.

Recently Browsing 0

  • No registered users viewing this page.