[Typo3] sys_language_uid doesn't bite!
David Smeringe
david.smeringe at 4yourlogo.com
Tue Oct 18 19:56:57 CEST 2005
1 - it's there - [GLOBAL]
2 - ok... :)
My TS setup for the standard template I have:
# ### CONFIGURE AUTOPARSER #####
# Configuring the Auto-Parser:
plugin.tx_automaketemplate_pi1 {
content < plugin.tx_rlmptmplselector_pi1
content.defaultTemplateFileName = main_template.html
content.defaultTemplateFileNameSub = clean_content.html
//content.inheritMainTemplates = 1
//content.inheritSubTemplates = 1
elements.BODY.all = 1
elements.BODY.subpartMarker = DOCUMENT_BODY
elements.HEAD.all = 1
elements.HEAD.subpartMarker = IN_HEADER
elements.HEAD.rmTagSections = title
elements.DIV.all = 1
elements.TD.all = 1
# Prefix all relative paths with this value:
relPathPrefix = fileadmin/template/main/
}
# Menu 1 cObject
temp.menu = HMENU
# First level menu-object, textual
temp.menu.1 = TMENU
temp.menu.1 {
# Normal state properties
NO.allWrap = <span class="menu_1_no"> | </span>
NO.stdWrap.htmlSpecialChars = 1
# Enable active state and set properties:
ACT = 1
ACT.allWrap = <span class="menu_1_act"> | </span>
ACT.stdWrap.htmlSpecialChars = 1
}
### HEAD TEMPLATE SETUP ###############
temp.headTemplate = TEMPLATE
temp.headTemplate {
template =< plugin.tx_automaketemplate_pi1
workOnSubpart = IN_HEADER
}
### CONTENT AREA TEMPLATE SETUP ######
temp.contentAreaTemplate = TEMPLATE
temp.contentAreaTemplate {
template =< plugin.tx_automaketemplate_pi1
// Modify the template selector config: This is a sub template!
template.content.templateType = sub
workOnSubpart = DOCUMENT_BODY
subparts {
colNormal < styles.content.get
colRight < styles.content.getRight
colLeft < styles.content.getLeft
colNormal.select.languageField=sys_language_uid
colRight.select.languageField=sys_language_uid
colLeft.select.languageField=sys_language_uid
# news-pi < plugin.tx_mininews_pi1
# news-pi.CMD = FP
}
subparts.pageTitle = TEXT
subparts.pageTitle.field = title
}
### MAIN TEMPLATE SETUP ###############
temp.mainTemplate = TEMPLATE
temp.mainTemplate {
template =< plugin.tx_automaketemplate_pi1
// Modify the template selector config: This is a sub template!
template.content.templateType = main
workOnSubpart = DOCUMENT_BODY
subparts.mainContent.select.languageField=sys_language_uid
subparts.mainContent < temp.contentAreaTemplate
subparts.menu_1 < temp.menu
}
### PAGE DIRECTIVES ###################
# Default PAGE object:
page = PAGE
page.typeNum = 0
page.select.languageField=sys_language_uid
page.config.doctype = xhtml_trans
#page.config.disableAllHeaderCode=1
page.config.admPanel = 1
#page.config.simulateStaticDocuments=PATH_INFO
page.10 < temp.mainTemplate
page.headerData.10 < temp.headTemplate
page.stylesheet = fileadmin/template/main/webb.css
config.linkVars=L
#Communicate in english
[globalVar = GP:L = 0]
config.sys_language_uid = 0
config.language = en
config.locale_all = english
page.config.language = en
#Speak swedish!
[globalVar = GP:L = 1]
config.sys_language_uid = 1
config.language = sv
config.locale_all = sv_SE
#return..
[GLOBAL]
........................
(end of TS setup for my template)
3- Yes. 0=default(english in my case) and 1=swedish.
Thanks for you time and effort Richard,
Regards,
David Smeringe
-----Ursprungligt meddelande-----
Från: typo3-english-bounces at lists.netfielders.de [mailto:typo3-english-bounces at lists.netfielders.de] För Richard Paquet
Skickat: den 18 oktober 2005 17:59
Till: TYPO3 English
Ämne: Re: [Typo3] sys_language_uid doesn't bite!
1- I not see this line "[GLOBAL]" on your setup, it's still there?
2- please show me your whole typoscript setup
3- At eh end of your url You see .......... &L=1
the &L=1 it is config.sys_language_uid = 1, your Swedish ?
Sorry for my bad english.
Richard :)
----- Original Message -----
From: "David Smeringe" <david.smeringe at 4yourlogo.com>
To: "TYPO3 English" <typo3-english at lists.netfielders.de>
Sent: Tuesday, October 18, 2005 10:44 AM
Subject: Re: [Typo3] sys_language_uid doesn't bite!
No, I've added (in this case) Swedish as a new website language and also
created a new translation of a page so that I can se the differences.
So, what I got is:
1 One default language which is English.
2 one extra website language - Swedish.
3 exactly the same globalVar/config setup as yours below.
4 Also using sr_language_menu (thought it might have some preset setup..)
..
That should be it, shouldn't it?
Hm. Just did a short test using
[globalVar = GP:L = 1]
page.20 = TEXT
page.20.value = hello
That works! I get "hello" when selecting language 1. So my problem should be
config.sys_language_uid, getting the correct translation of the page and not
the default as I do now?
Regards,
David Smeringe
-----Ursprungligt meddelande-----
Från: typo3-english-bounces at lists.netfielders.de
[mailto:typo3-english-bounces at lists.netfielders.de] För Richard Paquet
Skickat: den 18 oktober 2005 14:37
Till: TYPO3 English
Ämne: Re: [Typo3] sys_language_uid doesn't bite!
You dont forget to create your language? List->"your site Name"-> New
choose "website language"
In your setup try this and after put your language.
config.linkVars=L
#anglais GP:L est l'ID de cette langue rentrée à l'étape 1
[globalVar = GP:L = 1]
config.sys_language_uid = 1
config.language = en
config.locale_all = english
page.config.language = en
#config.metaCharset=iso-8859-1
#doit etre retourner pour que les langues marchent
[GLOBAL]
----- Original Message -----
From: "David Smeringe" <david.smeringe at 4yourlogo.com>
To: <typo3-english at lists.netfielders.de>
Sent: Tuesday, October 18, 2005 7:57 AM
Subject: [Typo3] sys_language_uid doesn't bite!
> Hi!
>
>
>
> I found a message posted here by Jesper Weissglas about sys_language_uid
> not working posted 22 of july 12:45 (I think it was this list). I have
> the same problem so I was wondering if there where any answers to that
> question? I've tried to follow all directives available, but the page
> only shows default language.
>
>
>
> My ts setup for lanuages:
>
>
>
> # setting up lang var
>
> config.linkVars = L
>
>
>
> # swedish language, sys_language.uid = 1
>
> [globalVar = GP:L = 1]
>
> config.sys_language_uid = 1
>
> config.language = se
>
>
>
>
>
> Please give some hints.
>
>
>
> Regards,
>
> David Smeringe
>
>
>
>
>
> _______________________________________________
> Typo3-english mailing list
> Typo3-english at lists.netfielders.de
> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
>
>
_______________________________________________
Typo3-english mailing list
Typo3-english at lists.netfielders.de
http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
_______________________________________________
Typo3-english mailing list
Typo3-english at lists.netfielders.de
http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
_______________________________________________
Typo3-english mailing list
Typo3-english at lists.netfielders.de
http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
More information about the TYPO3-english
mailing list