Zum Inhalt springen

Menü verschwindet ebenenweise nach "Template on next level"

Erstellt am 26. August 2005 · 1 Antwort · letzte Antwort am 26. August 2005

Tags: Templates & Layouts, Frage

mediaman ·

Moin allerseits,

ich möchte gerne eine zweite HTML-Vorlage in der zweiten Menüebene benutzen. Im Template-Modul habe ich dafür in der root-ebene "template on next level" gewählt und habe auf die erste Seite in der zweiten Menüebene verwiesen. In der seite habe ich eine Kopie meines Typoscripts hinterlegt, mit dem einzigen Unterschied, dass ich auf eine andere HTML-Vorlage verweise.

Das funktioniert eigentlich schon mehr oder weniger. Wenn ich nun Menüpunkte in der zweite Menüebene anwähle wird die neue HTML-Vorlage verwendet. Nur wenn ich nun ein Hauptmenüpunkt wähle verschwindet dieser und nur die Untermenüpunkte werden noch angezeigt. Wenn ich nun ein Untermenüpunkt auswähle, ist gar kein Menü mehr zu sehen o.O Wie kann man das verhindern?

Hier mein Typoscript aus der root-ebene. Das andere Script sieht genauso aus. Es verweist aber auf eine andere HTML-Vorlage

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


    # Here we define which elements in the HTML that 
    # should be wrapped in subpart-comments:
  elements {
    BODY.all = 1
    BODY.all.subpartMarker = DOCUMENT_BODY

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

    TD.all = 1
  }

    # Prefix all relative paths with this value:
  relPathPrefix = fileadmin/template/
}

# Menu 1 cObject erster Versuch
temp.mainmenu= HMENU
temp.mainmenu.excludeUidList = 17,18,19,20,22

  # First level menu-object, textual läuft

temp.mainmenu.1 = TMENU
temp.mainmenu.1 {
  expAll = 0
NO.allWrap=<div class="navigation_first"><IMG src="fileadmin/template/_gfx/dots_menu_first_level.gif" width="26" height="16" border="0" ALIGN="top" > | <div>
}

temp.mainmenu.2 = TMENU
temp.mainmenu.2 {
#MENU.entryLevel=2
  expAll = 0
NO.allWrap=<div class="navigation_second"><IMG src="fileadmin/template/_gfx/dots_menu_second_level.gif" width="63" height="31" border="0" ALIGN="middle">|</div>
}

temp.topmenu = HMENU
temp.topmenu.special = list
temp.topmenu.special.value = 17,18,22

temp.topmenu.1 = TMENU
temp.topmenu.1 {
  expAll = 1
NO.allWrap=<td class="top"> | &nbsp;&Iota;&nbsp;</td>
}

temp.bottommenu= HMENU
temp.bottommenu.special = list
temp.bottommenu.special.value = 19,20

  # First level menu-object, textual läuft

temp.bottommenu.1 = TMENU
temp.bottommenu.1 {
  expAll = 0
NO.allWrap=<td class="bottom"> | &nbsp;&Iota;&nbsp;</td>
}

# Main TEMPLATE cObject for the BODY
temp.mainTemplate = TEMPLATE
temp.mainTemplate {
    # Feeding the content from the Auto-parser to the TEMPLATE cObject:
  template =< plugin.tx_automaketemplate_pi1
#template =< plugin.tx_imgswopper4x4_pi1
    # Select only the content between the <body>-tags
  workOnSubpart = DOCUMENT_BODY

    # Substitute the ###menu_1### subpart with dynamic menu:
  subparts.mainmenu< temp.mainmenu
  subparts.topmenu < temp.topmenu
  subparts.bottommenu < temp.bottommenu


 
    # Substitute the ###content### subpart with some example content:
  #subparts.content = TEXT
  subparts.content.allWrap=<div class="content"> | </div>
 subparts.content < styles.content.get

  #subparts.CONTENT_RIGHT = TEXT
  #subparts.CONTENT_RIGHT.value = HELLO WORLD - CONTENT
 subparts.content_right< styles.content.getRight

subparts.content_left< styles.content.getLeft

}

# Main TEMPLATE cObject for the HEAD
temp.headTemplate = TEMPLATE
temp.headTemplate {
    # Feeding the content from the Auto-parser to the TEMPLATE cObject:
 template =< plugin.tx_automaketemplate_pi1
#template =< plugin.tx_imgswopper4x4_pi1
    # Select only the content between the <head>-tags
  workOnSubpart = DOCUMENT_HEADER
}

   
# Default PAGE object:
page = PAGE
page.typeNum = 0
page.stylesheet = fileadmin/template/_lib/styles.css

# Copying the content from TEMPLATE for <body>-section:
page.10 < temp.mainTemplate
# Copying the content from TEMPLATE for <head>-section:
page.headerData.10  < temp.headTemplate
mediaman ·

bevor sich einer den Kopf zerbricht. Ich habe vergessen bei den Template-Optionen beim zweiten Template das Häkchen vor Rootlevel weg zu nehmen 😃