I have a question regarding to the function of translating to browser language. I built my website in English. I check with browser with incognito mode in German . For the 1st time is German. Then i close the browser, and open my website with incognito mode again, it is back to English again. Even in this time, i change the language into German, but when i close and reopen, it’s back to English. I would like to ask if developers have solutions for this.
I build an ecommerce store, and the client may access to the website several times before deciding to buy the product. I mean not only in my case, but also in general that this improper function of gtranslate will significantly reduce the web user experience since the 2nd, 3rd time visit is clearly different to the 1st time.
Thank you.
Hi,
I am using the free version of Polylang on my WordPress site. However, I noticed that the “Detect Browser Language” feature is not working. When I go to Languages > Settings and click “Activate” next to “Detect Browser Language,” nothing happens. The button appears unresponsive.
Details:
? WordPress Version: 6.7.2
? Polylang Version: 3.6.6
? Theme: Blocksy (free version)
? Relevant Plugins: Connect Polylang for Elementor v2.4.5
? Hosting Provider: Hostinger
Troubleshooting Steps I Have Tried:
1. Cleared cache (LiteSpeed Cache plugin & browser cache).
2. Checked Polylang settings, but there is no indication of errors.
Is this a known issue, or has the “Detect Browser Language” feature been disabled for free users? Any advice on how to fix this would be greatly appreciated.
Thank you!
]]>went into all your phps but could not find the snippet. Your help would be very much appreciated
Thks Clarissa
]]>First of all thank you for your great work! I love Polylang!
I’m currently using Polylang for a website that is intended for several African countries, some of them french speaking, some english, some both (like Cameroun). My website provides an english (en_US) and a french (fr_FR) version, the english version is the default language. I use the “Detect browser language” feature and I wanted to know if a browser that is configured for fr_CM (fran?ais Caméroun) would automatically redirect to the fr_FR version of my website, or if it redirects to the default language, i.e. en_US in my case?
I would like browsers that are configured for french, regardless of the country code, to redirect to the fr_FR version, and similarly browsers, that are configured for english (example: Kenya), to redirect to the en_US version.
I have no way to test this myself, therefore I’m asking in the forum how the automatic redirection works. (I did not read the code either, which might give me the answer.)
The cookie set by Polylang seems to contain only the language, not the country code. This might already be the answer to my question..
If this redirection is country code based, how could I force Polylang to redirect to the language, regardless of the country code?
Any experiences with this?
Thank you!
]]>Any help appreciated
Tom
Or is it a functionality included in paid version?
Thank you.
Renato
I have a problem with “Detect browser language” settings which doesn’t working at all. Is it possible to fix this somehow?
Additionally we’ve faced the following problem:
Sometimes it happens that it’s not possible to switch from Spanish (2nd language) to English (default language). The problem appears from time to time and we can’t find the reason so far. Even if the ?Detect browser language? is turned off the problem remains.?
Settings:
Default Lang: ‘en’,
Detect browser language: Deactivated,
URL Modifications > Language set from content: false,
URL Modifications > Language set from directory name in pretty permalinks: true,
URL Modifications > Language set from subdomain: false,
URL Modifications > Language set from diff domains: false,
URL Modifications > Hide URL lang info for default: true,
URL Modifications > Remove /language/ in permalinks: true,
URL Modifications > Keep /language/ in permalinks: false,
URL Modifications > Front page url contains lang code instead of page name/id: true
Thanks in advance
]]>I have 2 child themes, one for the main site and one for the sub-domain.
I edited the functions.php file of the child theme used for the main site.
`add_action( ‘template_redirect’, ‘custom_lang_found’ );
function custom_lang_found(){
$lang = substr($_SERVER[‘HTTP_ACCEPT_LANGUAGE’], 0, 2);
if($lang == “fr” && is_home() {
wp_redirect(‘https://fr.mysite.com’); die();}
}`
When I use this code, the condition is_home() seems not to work. I can’t access my WordPress network interface and when I access my main site WordPress interface I am redirected to my sub-domain.
When I go to my main site homepage (my browser is in French), I am redirected to my sub-domain.
For some reasons, Geo Redirect doesn’t work.
]]>