Project

General

Profile

Actions

Feature #20955

closed

Override FE labels with XML files

Added by Christian Kuhn about 15 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Category:
-
Target version:
-
Start date:
2009-08-30
Due date:
% Done:

0%

Estimated time:
PHP Version:
5.2
Tags:
Complexity:
Sprint Focus:

Description

Problem:
It's currently impossible to override FE labels with own labels defined in XML files. The only way to override labels in FE is via TS "_LOCAL_LANG", while overriding labels in BE is already possible with XML files ($TYPO3_CONF_VARS['BE']['XLLfile'])

Solution:
Add a new global $TYPO3_CONF_VARS['XLL'] to register XML overrides for FE and BE labels and handle registered files in t3lib_div::readLLfile . FE TS _LOCAL_LANG overrides still takes precedence of registered XML files.

Background:
Translation agencies often have no problems exporting language overrides in a well-formed XML file, that can easily registered with a language override extension. But they have problems exporting labels to the _LOCAL_LANG TS format.

Example on how to test:
- Add a felogin content element to your page
- You will see the label "Enter your username and password here in order to log in on the website:" in FE
- Install attached "langtest" extension, it will register a FE pi1 and a BE locallang file to $TYPO3_CONF_VARS['XLL']
- Your FE label will now switch to "LANG DEFAULT XML OVERRIDE", another registered BE override will switch the second tab of the BE content element to LANG DEFAULT XML OVERRIDE Redirect Options
- Override the FE label via TS, eg:
plugin.tx_felogin_pi1 {
_LOCAL_LANG {
default.ll_welcome_message = LANG DEFAULT TS OVERRIDE
}
}
- Play with different languages and overrides, the test extension shows some examples.

Notes:
As this solution handles FE and BE exactly the same way, we might could deprecate $TYPO3_CONF_VARS['BE']['XLLfile'] in a follow-up RFC.

(issue imported from #M11825)


Files

T3X_langtest-0_0_0-z-200908301823.t3x (1.57 KB) T3X_langtest-0_0_0-z-200908301823.t3x Administrator Admin, 2009-08-30 18:23
11825_v1.diff (1.48 KB) 11825_v1.diff Administrator Admin, 2009-08-30 18:23
11825_v2.diff (2.16 KB) 11825_v2.diff Administrator Admin, 2009-09-01 00:25
T3X_langtest-0_0_0-z-200908311359.t3x (1.58 KB) T3X_langtest-0_0_0-z-200908311359.t3x Administrator Admin, 2009-09-01 00:25

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #23697: locallangXMLOverride should not distinguish between paths ending with php and xml (like readLLfile does)ClosedSteffen Gebert2010-10-09

Actions
Actions

Also available in: Atom PDF