12. 04. 2005, 15:08

Hi,
bin absoluter Newbie mit Typo3

Habe von meinem Chef eine halbfertige Site bekommen die ich jetzt fertigstellen soll.

Es gibt 2 Sprachen : default=Englisch L=0 und L=1 ist deutsch....
habe für jede Seite auch schon eine Übersetzung angelegt.

Wenn man manuell die Seiten mit ?L=1 oder ?L=0 an den Link angehängt aufruft, funktioniert das auch alles schon.

Jetzt das Problem:

Im Hauptmenü will beim Chef, dass nur die Fahne angezeigt wird, desse Sprache gerade nicht aktiv ist.

also wenn ich die Seite in Englisch aufrufe, soll im Menü eine deutsche Flagge erscheinen, die dann auf deutsch umschaltet und umgekehrt....

ich habe keine Ahnung wie ich das bewerkstelligen soll.

Im Setup steht folgendes:
[code:1:7b51460cdb]
config.admPanel = 0

# - - - language specific (default)
config.linkVars = L
config.sys_language_uid = 0
config.language = en
config.locale_all = en
plugin.meta.global.description = english description
plugin.meta.global.keywords = english, keywords
plugin.tx_indexedsearch._DEFAULT_PI_VARS.lang = 0

lib.lang_url = TEXT
lib.lang_url.value = index.php?id={page:uid}&L=1
lib.lang_url.htmlSpecialChars = 1
lib.lang_url.insertData = 1
lib.lang_label = TEXT
lib.lang_label.value = English
lib.imprint_label = TEXT
lib.imprint_label.value = Impressum

# - - - language specific (english)
[globalVar=GP:L=1]
config.sys_language_uid = 1
config.language = de
config.locale_all = de_DE
plugin.meta.global.description = desc...
plugin.meta.global.keywords = german, keywords, coming here...

plugin.tx_indexedsearch._DEFAULT_PI_VARS.lang = 1
# tt_content.search.20.layout.10.value = Search result: ###RANGELOW###-###RANGEHIGH### of ###TOTAL###
lib.lang_url.value = index.php?id={page:uid}&L=0
lib.lang_label.value = Deutsch
lib.imprint_label.value = Imprint
[global]

# subheader
lib.subheader = HMENU
lib.subheader {
special = rootline
special {
range = 1|1
}
1 = TMENU
1 {
NO.doNotLinkIt = |*||*|1
NO.stdWrap.cObject = COA
NO.stdWrap.cObject {
10 = TEXT
10.field = subtitle
10.htmlSpecialChars = 1
}
}
}

# kopfzeile menu template
lib.menu_level1 = HMENU
lib.menu_level1.1 = TMENU
lib.menu_level1.1 {
NO.allWrap = <span class="level1_inact"> | </span><span class="level1_inact"> | </span> |*||*| <span class="level1_inact"> | </span>
NO.stdWrap.case = upper
ACT = 1
ACT.stdWrap.case = upper
ACT.allWrap = <span class="level1_act"> | </span><span class="level1_inact"> | </span> |*||*| <span class="level1_act"> | </span>
ACT.stdWrap.case = upper
}

# menu links template
lib.menu_level2 = HMENU
lib.menu_level2 {
entryLevel = 1
1 = TMENU
2 = TMENU
1 {
NO.allWrap = <tr><td><img src="fileadmin/templates/images/void.gif" height="12px" width="9px"></td><td><img src="fileadmin/templates/images/void.gif" height="1px" width="5px"></td><td class="submenu_inactive" valign="top">|</td></tr><tr><td colspan="3"><img src="fileadmin/templates/images/void.gif" height="16px" width="1px"></td></tr>
ACT = 1
ACT.allWrap = <tr><td valign="top"><img src="fileadmin/templates/images/pfeil.gif" height="12px" width="9px"></td><td><img src="fileadmin/templates/images/void.gif" height="1px" width="5px"></td><td class="submenu_active" valign="top">|</td></tr><tr><td colspan="3"><img src="fileadmin/templates/images/void.gif" height="16px" width="1px"></td></tr>
}
2 {
NO.allWrap = <p class="menu_level3">|</p>
ACT = 1
ACT.allWrap = <p class="menu_level3_act">|</p>
}
}

tt_content.stdWrap.dataWrap = {$content.mainWrap}

# Wrap for contentelement headers
lib.stdheader.stdWrap.wrap = {$content.headerWrap}

# Wrap for body of contentelement type: TEXT
tt_content.text.20.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: HTML
tt_content.html.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: IMAGE and IMGTEXT
tt_content.image.15 = TEXT
tt_content.image.15.value = {$content.bodyWrapStart}
tt_content.image.999 = TEXT
tt_content.image.999.value = {$content.bodyWrapEnd}
tt_content.image.20.text.20.wrap = |

tt_content.textpic.15 = TEXT
tt_content.textpic.15.value = {$content.bodyWrapStart}
tt_content.textpic.999 = TEXT
tt_content.textpic.999.value = {$content.bodyWrapEnd}
tt_content.textpic.20.text.20.wrap = |

# Wrap for body of contentelement type: BULLET
tt_content.bullets.20.stdWrap.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: TABLE
tt_content.table.20.stdWrap.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: UPLOADS (Filelinks)
tt_content.uploads.20.stdWrap.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: MENU
tt_content.menu.20.stdWrap.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: SHORTCUT?
tt_content.shortcut.20.stdWrap.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: LIST (Plugins)
tt_content.list.20.stdWrap.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: MULTIMEDIA
tt_content.multimedia.20.stdWrap.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: MAILFORM
tt_content.mailform.20.stdWrap.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: SEARCH
# Search Results
tt_content.search.20.stdWrap.wrap = {$content.bodyWrap}
# Search Form
tt_content.search.30.stdWrap.wrap = {$content.bodyWrap}

# Wrap for body of contentelement type: LOGIN
tt_content.login.20.stdWrap.wrap = {$content.bodyWrap}

# Configuring the Auto-Parser
plugin.tx_automaketemplate_pi1 {
# Read template file
content = FILE
content.file = fileadmin/templates/template.html

elements {
BODY.all = 1
BODY.all.subpartMarker = DOCUMENT_BODY

HEAD.all = 1
HEAD.all.subpartMarker = DOCUMENT_HEADER
HEAD.rmTagSections = title

TD.all = 1
TABLE.all = 1
}
}

lib.stdheader.stdWrap.dataWrap >

# Create COA with different maxW for right column
temp.rightContent = COA
temp.rightContent {
10 = LOAD_REGISTER
10.maxImageWidth = 150
20 < styles.content.getRight
30 = RESTORE_REGISTER
}

# Body template
temp.mainTemplate = TEMPLATE
temp.mainTemplate {
template =< plugin.tx_automaketemplate_pi1

subparts.menu_level1 < lib.menu_level1
subparts.menu_level2 < lib.menu_level2
subparts.subheader < lib.subheader
subparts.main < styles.content.get
#use the one created above instead of styles.content.getRight
subparts.right < temp.rightContent
}

#Header template
temp.headerTemplate = TEMPLATE
temp.headerTemplate {
template =< plugin.tx_automaketemplate_pi1
workOnSubpart = DOCUMENT_HEADER
}

# Footer Template
temp.footer = TEXT
temp.footer.value = <div class="footer">Site and graphics
created and maintained by Netzwert AG <br>© 2005
All Rights Reserved * info(at)Netzwert.ag *</div>
}

# Default PAGE object:
page = PAGE
page.typeNum = 0
page.stylesheet = fileadmin/templates/style.css

page.10 < temp.mainTemplate
# susys insertion
page.10.43 = PHP_SCRIPT
page.10.43.file = media/scripts/my_languageMenu.php
# end susys insertion
[/code:1:7b51460cdb]

Soweit ich es verstanden habe, dass ich noch irgendwie was im template.html einbauen muss....damit die Fahne ins Menü kommt und das my_languageMenu.php muss auch
angepasst werden ( ist im Moment nur das Beispiel).

Hat jemand Lust und Geduld mir da zu helfen ?

Danke
Susy

[/code]