[TYPO3-english] dataWrap returns only LLL strings of default language

Lukas Stancik webmaster at robe.cz
Sun Dec 19 22:25:00 CET 2010


Dne 13.12.2010 23:38, Lukas Stancik napsal(a):
> Hi guys,
>
> I'd like to ask you kindly for a bit of help. I'm trying to output a
> simple text in FE depending on the language selected using this code:
>
> 20 = TEXT
> 20 {
> field = title
> dataWrap = {LLL:fileadmin/translations.xml:labelTitle}:|
> }
>
> the translations.xml file content is as follows:
>
> <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
> <T3locallang>
> <meta type="array">
> <description>language labels</description>
> <type>database</type>
> </meta>
> <data type="array">
> <languageKey index="default" type="array">
> <label index="labelTitle">label in default language</label>
> </languageKey>
> <languageKey index="ru" type="array">
> <label index="labelTitle">label in Russian language</label>
> </languageKey>
> </data>
> </T3locallang>
>
>
> The problem is that even if the Russian language is selected [GP:L value
> is set to 5 which is Russian in my case] the dataWrap outputs the label
> string of the "default" language. Is there something wrong with the
> code? I'm unable to see something obvious maybe after such an amount of
> time I've been dealing with it.
>
> Thanks for any suggestions in advance!
>
> Best Regards,
> Lukas Stancik

Just in case anyone runs into the same problem - make sure you have 
config.language = XX setting in your template

Regards,
Lukas Stancik



More information about the TYPO3-english mailing list