Project

General

Profile

Actions

Bug #27971

closed

xliff removed hook to override locallangs

Added by Georg Ringer over 13 years ago. Updated about 13 years ago.

Status:
Rejected
Priority:
Must have
Assignee:
-
Category:
Backend API
Target version:
Start date:
2011-07-08
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.6
PHP Version:
5.3
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

There was a hook in t3lib_div::readLLFile() to override any locallang file by another one. The additional locallang is merged with the existing one which is very nice feature to override just one label.

as the l10n changed a lot with xliff, it is not just a copy paste to get hook working again.
previous hook was this

$overrides = array();
            $fileRefWithoutExtension = preg_replace('/\.(php|xml)$/', '', $fileRef);

            if (is_array($GLOBALS['TYPO3_CONF_VARS']['SYS']['locallangXMLOverride'][$fileRefWithoutExtension . '.php'])) {
                $overrides = array_merge($overrides, $GLOBALS['TYPO3_CONF_VARS']['SYS']['locallangXMLOverride'][$fileRefWithoutExtension . '.php']);
            }
            if (is_array($GLOBALS['TYPO3_CONF_VARS']['SYS']['locallangXMLOverride'][$fileRefWithoutExtension . '.xml'])) {
                $overrides = array_merge($overrides, $GLOBALS['TYPO3_CONF_VARS']['SYS']['locallangXMLOverride'][$fileRefWithoutExtension . '.xml']);
            }

            if (count($overrides) > 0) {
                foreach ($overrides as $overrideFile) {
                    $languageOverrideFileName = self::getFileAbsFileName($overrideFile);
                    if (@is_file($languageOverrideFileName)) {
                        $languageOverrideArray = self::readLLXMLfile($languageOverrideFileName, $langKey, $charset);
                        $LOCAL_LANG = self::array_merge_recursive_overrule($LOCAL_LANG, $languageOverrideArray);
                    }
                }
            }

Related issues 1 (0 open1 closed)

Is duplicate of TYPO3 Core - Bug #27923: locallangXMLOverride hook has been removedClosedXavier Perseguers2011-07-06

Actions
Actions

Also available in: Atom PDF