Issue Bug Closed

#102579typo3Language Site Configuration set to a full locale instead of language key

Garvin Hicking 12/01/23, 13:04 updated 07/09/24, 15:12

Description

https://docs.typo3.org/c/typo3/cms-core/main/en-us/Changelog/12.3/Deprecation-99882-SiteLanguageTypo3LanguageSetting.html introduced a autodetection method for the “typo3Language” option.

The autodetection uses:

        $typo3Language = $this->locale->getLanguageCode();
        if ($this->locale->getCountryCode()) {
            $typo3Language .= '_' . $this->locale->getCountryCode();
        }

Appending the Country Code to a string like “de” or “en” will lead to a language key like “de_DE”, which then searches for files called `de_DE.locallang.xlf` – but the files are (usually? always?) called `de.locallang.xlf`.

Reviews 3