DirkPersky/typo3-dp_cookieconsent

_LOCAL_LANG translations not working

MarcelKohler opened this issue · 3 comments

Hi,
I am currently experiencing difficulties with the translation feature for your cookie message. Specifically, it does not seem to be functioning correctly at the moment. My approach was based on the guidelines provided here: https://docs.typo3.org/p/dirkpersky/typo3-dp_cookieconsent/main/en-us/Configuration/Language.html.

For reference, I am using TYPO3 version 12.4.8, t3sbootstrap version 5.3.2, and dp_cookieconsent version 12.1.4. I have also ensured that the t3sbootstrap cookie option is disabled.

Any assistance or guidance would be greatly appreciated.

He,

there is a workaround:
#116 (comment)

At the moment i dont know exactly why 12LTS dosnt' do it, the basic way.

Thank you so much! That worked!
For future reference (if anyone clicks on this bug), here is my solution:

ext_localconf.php

$GLOBALS['TYPO3_CONF_VARS']['SYS']['locallangXMLOverride']['de']
['EXT:dp_cookieconsent/Resources/Private/Language/locallang.xlf'][]
= 'EXT:your_extension/Resources/Private/Language/custom.xlf';

Then create the Resources/Private/Language/custom.xlf within your own extension and override for example the "message" field like this:

<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<xliff version="1.0">
    <file source-language="en" datatype="plaintext" date="2013-03-09T18:44:59Z" product-name="your_extension">
        <header/>
        <body>
	   <trans-unit id="message">
               <source>We use cookies and other tracking technologies to personalize and improve your experience. By continuing to use our website you consent to this.</source>
               <target>Your Cookie Translation</target>
            </trans-unit>
        </body>
    </file>
</xliff>

And don't forget to use "Manage Languages" to download the updated language packs. ;)

He,

there is a workaround: #116 (comment)

At the moment i dont know exactly why 12LTS dosnt' do it, the basic way.

Funny Story:
They finally patched it in 12.4.9 (https://get.typo3.org/release-notes/12.4.9).
So no need to use the workaround I posted here earlier... :D