Actions
Task #99692
closedRemove hardcoded "Translate to:" in DataMapProcessor
Status:
Closed
Priority:
Won't have this time
Assignee:
-
Category:
Localization
Target version:
-
Start date:
2023-01-24
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
10
PHP Version:
8.0
Tags:
Complexity:
easy
Sprint Focus:
Description
When a record in TYPO3 backend is translated it will be prefixed by default with string "Translate to: ".
According to the documentation it should be possible to adjust the prefix. In some cases this prefix may be empty:
TCEMAIN.translateToMessage =
BUT in DataMapProcessor this empty line will be overwritten with hardcoded initial value "Translated to: ". So there is no posibility to surpress this prefix.
/typo3/sysext/core/Classes/DataHandling/Localization/DataMapProcessor.php
$tsConfigTranslateToMessage = BackendUtility::getPagesTSconfig($pageId)['TCEMAIN.']['translateToMessage'] ?? '';
if (!empty($tsConfigTranslateToMessage)) {
$prefix = $tsConfigTranslateToMessage;
if ($languageService !== null) {
$prefix = $languageService->sL($prefix);
}
$prefix = sprintf($prefix, $languageRecord['title']);
}
if (empty($prefix)) {
$prefix = 'Translate to ' . $languageRecord['title'] . ':';
}
Why does this fallback exists and can we remove it?
Updated by Eric Harrer 10 months ago
Your code snippet seems to still refer to version 10.4.
This hardcoded string already has been removed in TYPO3 v11 and up.
Updated by Eric Harrer 10 months ago
- Related to Epic #101557: Translation Handling Findings added
Updated by Eric Harrer 10 months ago
- Related to deleted (Epic #101557: Translation Handling Findings)
Updated by Eric Harrer 10 months ago
- Related to Story #101561: DataHandler related translation issues added
Updated by Jo Hasenau 10 months ago
- Status changed from New to Closed
- Priority changed from Should have to Won't have this time
This is fixed in 11 and won't be fixed in 10 due to ELTS.
Actions