Hi BastianBalthasarBux!
Ich kämpfe leider auch mit dem templateselector.
ich habe mich an deinen oben angegebenen Code gehalten, habe ihn angepasst, kann auch die Templates auswählen - aber ich bekomme eine leere Seite. Nada, nix, weiß 🙁
Ich poste jetzt mal meinen Code und dann hab ich noch zwei Fragen. Vieleicht kannst Du mir helfen, weil ich schon ziemlich am Zahnfleisch bin.
[TS
lib {
logo = IMAGE
logo {
wrap = <a href="/" alt="HPC dual" title="HPC dual">|</a>
file = fileadmin/img/logo.gif
altText.field = description // subtitle // nav_title // title
titleText.field = description // subtitle // nav_title // title
}
langselect = TEXT
langselect.value = <div id="langpack"><a href="index.php?id=1"><div class="ger"> </div><a href="index.php?id=14"><div class="eng"> </div></a></div>
}
### Example by Riccabona eSolutions, no warranty
### Default content template
temp.objPageMainContent = TEMPLATE
temp.objPageMainContent {
template = FILE
template.file = fileadmin/templates/template_std.html
workOnSubpart = DOKUMENT
workOnSubpart = SUBCONTENT
marks.CONTENT_MAIN < styles.content.get
}
### Content with infobox
temp.objMainInfoBox = TEMPLATE
temp.objMainInfoBox {
template = FILE
template.file = fileadmin/templates/template_info.html
workOnSubpart = DOKUMENT
workOnSubpart = SUBCONTENT
marks {
CLEFT = CONTENT
CLEFT {
table = tt_content
select.orderBy = sorting
select.begin = 0
select.max = 1
}
CIHEAD = CONTENT
CIHEAD {
table = tt_content
select.orderBy = sorting
select.begin = 1
select.max = 1
}
CITXT = CONTENT
CITXT {
table = tt_content
select.orderBy = sorting
select.begin = 2
select.max = 1
}
}
}
### The Startpage
### temp.objPageMainStart = TEMPLATE
### temp.objPageMainStart {
### template = FILE
### template.file = fileadmin/tmpl/start.tmpl
### workOnSubpart = ...
### .
### .
### .
### }
### Configurating the Template Selector
temp.objMainContent = TEMPLATE
temp.objMainContent {
tx_rlmptmplselector.title = Vorlage - 1 spaltiger Inhalt
#tx_rlmptmplselector.imagefile = fileadmin/img/pageContentMain.gif
template = COA
template.10 < temp.objPageMainContent
}
temp.objMainContentInfo = TEMPLATE
temp.objMainContentInfo {
tx_rlmptmplselector.title = Vorlage - mit seitlicher Infobox
#tx_rlmptmplselector.imagefile = fileadmin/img/pageContentMain2Cols.gif
template = COA
template.10 < temp.objMainInfoBox
}
#temp.objMainStart = TEMPLATE
#temp.objMainStart {
# tx_rlmptmplselector.title = Hauptvorlage - Startseite
# tx_rlmptmplselector.imagefile = fileadmin/img/page_main_start.gif
# template = COA
# template.10 < temp.objPageMainStart
#}
### Templateselector Core Definitions
plugin.tx_rlmptmplselector_pi1 {
templateObjects.main {
10 < temp.objMainContent
20 < temp.objMainContentInfo
#30 < temp.objMainStart
}
templateObjects.sub {
}
defaultTemplateObjectMain = 10
defaultTemplateObjectSub = 10
inheritMainTemplates = 0
inheritSubTemplates = 0
}
]
Was nicht hier herinnen ist, ist der Aufbau des Menüs. Ich hab meine seite so aufgebaut, dass ich lib, header, config und dann das rootTemplate habe.
Und beim RootTemplate liegt wahrscheinlich auch mein Fehler. Aber hier mal der Code:
[/TS
page.10 = TEMPLATE
page.10 {
template = plugin.tx_rlmp_templateselector_pi1
workOnSubpart = DOCUMENT
marks.LOGO < lib.logo
marks.LANG < lib.langselect
marks.M1 = HMENU
marks.M1.special = directory
marks.M1.special.value = 1
marks.M1.1 = TMENU
marks.M1.1.noBlur = 1
marks.M1.1 {
wrap = <div id="navcontainer"><ul id="navlist">|</ul></div>
expAll = 1
NO.ATagParams = onFocus="if (this.blur) this.blur()"
NO.wrapItemAndSub = <li>|</li>
ACT < .NO
ACT = 1
ACT.ATagParams = class="menu_active"
}
marks.CONTENT_MAIN < styles.content.get
}
]
Meine Frage und Überlegung ist, dass das Menü hier wahrscheinlich falsch liegt. Wenn ja wo leg ich es an und wie geht das mit Untermenüs.
Aber am wichigsten ist, das ich mal keine weiße Seite sehe.
Kannst du mir da helfen?
lg
rat_pack