Project

General

Profile

Actions

Bug #104064

closed

English is always taken as default xlf language

Added by Nicole Cordes 5 months ago. Updated 4 months ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2024-06-11
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
12
PHP Version:
Tags:
Complexity:
Is Regression:
Yes
Sprint Focus:

Description

Given:

- a site configuration having an German and English language
- an Extension providing German labels as default in locallang.xlf and English labels in en.locallang.xlf file

Expected:

- labels on an English page are shown in English

Actual:

- labels on the English page are shown in German

This scenario worked fine before TYPO3 12. It's maybe related to the patch https://review.typo3.org/c/Packages/TYPO3.CMS/+/77558 where the English locale "en" is hardcoded as "default" language (https://review.typo3.org/c/Packages/TYPO3.CMS/+/77558/8/typo3/sysext/core/Classes/Localization/LanguageService.php#323). If those lines are removed, everything works as expected.


Related issues 3 (1 open2 closed)

Related to TYPO3 Core - Feature #103905: Make default language uid configurableUnder ReviewAndré Buchmann2024-05-24

Actions
Related to TYPO3 Core - Bug #74380: TypoScript interpret XLF wrong for Default-Language (german) and englishClosed2016-03-06

Actions
Related to TYPO3 Core - Bug #104468: Allow non-english languages as FE default languageClosed2024-07-24

Actions
Actions #1

Updated by Garvin Hicking 5 months ago

Actions #2

Updated by Georg Ringer 5 months ago

  • Related to Bug #74380: TypoScript interpret XLF wrong for Default-Language (german) and english added
Actions #3

Updated by Georg Ringer 5 months ago

  • Status changed from New to Needs Feedback

hey nicole,

I wonder if this should be allowed (again) as the docs like https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/ApiOverview/Localization/XliffFormat.html also state that default is always english.

also all other files from offical localizations are english by default and de.locallang.xlf for translations.

I also sometimes misuse the default locallang.xlf with german when the site is german only but as soon as a 2nd language is added, I simply modify it to fit the correct way.

would that be fine for you as well and I would then close the issue

Actions #4

Updated by Nicole Cordes 5 months ago

  • Status changed from Needs Feedback to Resolved

Hi Georg,

Thanks for pointing me to the documentation resource. I wasn't aware that this was changed officially. Also the old behaviour still worked in v11.5. I migrated our xlf-files to include the correct (english) default and provide alternative languages as fallback.

Actions #5

Updated by Benni Mack 5 months ago

  • Status changed from Resolved to Closed
Actions #6

Updated by Georg Ringer 4 months ago

  • Related to Bug #104468: Allow non-english languages as FE default language added
Actions #7

Updated by Hannes Lau 4 months ago

Oh, I am sorry for the dupe. We can close my #104468 as duplicate.

But on the topic: I actually think that forcing english as the source language for frontend translation is a bad idea. Even pages that offer an english translation often start in a different language and get translated to English later in the process. Most translation agencies I have worked with had issues to translate a xx.locallang.xlf from target to source. And it also required me to update the default locallang.xlf after the english translation.

To my eyes it would be nice if projects could still pick the source language for the xlf files.

I personally think that this issue should be reopened. Removing the lines that Nicole referred to did not seem to have a bad effect on first sight.

Actions

Also available in: Atom PDF