[TYPO3] Language condition

JoH asenau info at cybercraft.de
Fri Jun 29 11:57:45 CEST 2007


>> $------------Code begin-----------------------------------$
>> #Site Slogan
>> lib.slogan = TEXT
>> lib.slogan.value = Making known to our community the God that brings
>> true freedom.
>> [language = es]
>> lib.slogan.value = Dando a conocer a nuestra comunidad al Dios que
>> trae
>> verdadera libertad.
>> [language]
>> lib.slogan.wrap = <h1 id="slogan">|</h1>
>> $-------------------------Code end-----------------------------$
>
> I wonder where you found that syntax... that's not the way languages
> are tested. You should have something like:

Well it is, but not together with a language switch in the FE output.
[language = blah] is checking HTTP_ACCEPT_LANGUAGE
which doesn't make much sense if you just click on a link.

> #Site Slogan
> lib.slogan = TEXT
> lib.slogan.value = Making known to our community the God that brings
> true freedom.
> [globalVar = GP:L = xx]
> lib.slogan.value = Dando a conocer a nuestra comunidad al Dios que
> trae verdadera libertad.
> [global]
> lib.slogan.wrap = <h1 id="slogan">|</h1>
>
> where "xx" is the uid of the Website language record you defined for
> Spanish. Please also mind the closing of the condition ([global] not
> [language]).

And by the way, it doesn't matter if you call your language parameter L or
LANG or BLAH, since the switch is done by TypoScript only. But you are
right, the common way is to use L for that purpose.

HTH

Joey

-- 
Wenn man keine Ahnung hat: Einfach mal Fresse halten!
(If you have no clues: simply shut your gob sometimes!)
Dieter Nuhr, German comedian
openBC/Xing: http://www.cybercraft.de
T3 cookbook: http://www.typo3experts.com




More information about the TYPO3-english mailing list