FEATURE Respects 'lang' stored in cookies

ENHANCEMENT choose_site_lang() accepts $availableLang (useful to check if a certain page has a translation, and fall back to default language)
ENHANCEMENT Added documentation
BUGFIX Rewrote Member->Lang to Member->Locale (CMS-translations are stored in locales as well), limited Locale Varchar to 6 characters, changed profile dropdown accordingly

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@43659 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Ingo Schommer 2007-10-21 19:53:57 +00:00
parent 2befee113b
commit 7912559ec8

View File

@ -14,8 +14,8 @@ abstract class LeftAndMain extends Controller {
// set language
$member = Member::currentUser();
if(!empty($member->Lang)) {
i18n::set_locale($member->Lang);
if(!empty($member->Locale)) {
i18n::set_locale($member->Locale);
}
parent::init();