Actions

Difference between revisions of "Multilingual-problems-after-updating-to-2.5.11-or-3.1.1"

From Joomla! Documentation

Line 1: Line 1:
Some (but not all) multilingual sites experience a problem where all content not in the default language is not displayed and the language filter module does not seem to work.  Although an official fix is not yet announced, this is related to the change to language cookie handling that was introduced.  As a first step  try opening the language filter plugin and set the cookie lifetime to year and see if that solves the problem.  If it does not as a '''temporary''' solution you may want to revert the change to the plugin. To do so take the code from the code below and change the plugin. Delete the lines with + at the beginning and add the lines with - at the beginning in the file plugins/system/languagefilter/languagefilter.php.
+
Some (but not all) multilingual sites experience a problem where all content not in the default language is not displayed and the language filter module does not seem to work.  
  
  
 +
An official fix is not yet announced.  However there were two changes that may be causing this issue and users may want to try fixing these. Try each fix in order and test to see if it resolves the problem.
  
@@ -82,7 +84,7 @@
+
First, open the language filter plugin, make sure the cookie lifetime is set to year and save.
$conf = JFactory::getConfig();
+
 
$cookie_domain = $conf->get('config.cookie_domain', '');
+
Second, if you have contact data you must ensure that every contact has a language (if it says "undefined" in the contact manager, that tells you no language is assigned) and every contact that has a linked user should have a version with language ALL as well as any specific language versions.
$cookie_path = $conf->get('config.cookie_path', '/');
+
- setcookie(JApplication::getHash('language'), $lang_code, time() + 365 * 86400, $cookie_path, $cookie_domain);
+
+ setcookie(JApplication::getHash('language'), $lang_code, $this->getLangCookieTime(), $cookie_path, $cookie_domain);
+
// set the request var
+
JRequest::setVar('language', $lang_code);
+
}
+
@@ -355,7 +357,7 @@
+
$conf = JFactory::getConfig();
+
$cookie_domain = $conf->get('config.cookie_domain', '');
+
$cookie_path = $conf->get('config.cookie_path', '/');
+
- setcookie(JApplication::getHash('language'), $lang_code, time() + 365 * 86400, $cookie_path, $cookie_domain);
+
+ setcookie(JApplication::getHash('language'), $lang_code, $this->getLangCookieTime(), $cookie_path, $cookie_domain);
+
}
+
}
+
}
+
  
  

Revision as of 10:41, 28 April 2013

Some (but not all) multilingual sites experience a problem where all content not in the default language is not displayed and the language filter module does not seem to work.


An official fix is not yet announced. However there were two changes that may be causing this issue and users may want to try fixing these. Try each fix in order and test to see if it resolves the problem.

First, open the language filter plugin, make sure the cookie lifetime is set to year and save.

Second, if you have contact data you must ensure that every contact has a language (if it says "undefined" in the contact manager, that tells you no language is assigned) and every contact that has a linked user should have a version with language ALL as well as any specific language versions.