[TYPO3-core] RFC #9402: Create a common_locallang-file

Steffen Kamper info at sk-typo3.de
Tue Sep 23 15:18:31 CEST 2008


Christopher schrieb:
> Hi Dmitry!
> 
> "Dmitry Dulepov [typo3]" schrieb im Newsbeitrag 
> news:mailman.1.1222161185.1329.typo3-team-core at lists.netfielders.de...
>> Benjamin Mack wrote:
>>> One question: do we need the prefix "common_" before ever label? We're 
>>> gonna use this like that
>>>
>>> $GLOBALS['LANG']->sL('EXT:lang/common.xml:yes');
>>>
>>> instead of
>>>
>>> $GLOBALS['LANG']->sL('EXT:lang/common.xml:common_yes');
>> But than you cannot use includeLLfile and getLL. You risk to have 
>> conflicts with other included language files. I prefer prefixes.
> 
> 
> Can you explain where you see this conflict?
> Let's try if I get it:
> 
> If I set something like
> $GLOBALS['LANG']->includeLLFile('EXT:xxx/locallang.xml');
> I can use the following to get a label:
> $GLOBALS['LANG']->getLL('yes', true),
> 
> Where is there the problem if I at some place in the file also use the 
> following:
> $GLOBALS['LANG']->sL('EXT:lang/common.xml:common_yes');
> 
> Do you mean that the line using getLL() won't work anymore in that case?
> 
> Christopher 
> 
> 

the conflict might be there if other lang-file also have a label "yes" 
so it will be overwritten.

For long sight i don't see this problem as these common terms are no 
longer needed in other lang files.
Additionally $LANG could include this file all the time as first file so 
we don't have a conflict and noone has to include this manually

vg Steffen


More information about the TYPO3-team-core mailing list