TYPO 4.5.29
Ich habe ein simples Fluid-Template:
<f:layout name="main" />
<f:section name="metaNavi">
<f:cObject typoscriptObjectPath="lib.metaMenu" />
</f:section>
<f:section name="PageLogo">
<f:cObject typoscriptObjectPath="lib.PageLogo">Logo1 Bild gerendert</f:cObject>
</f:section>
<f:section name="titelzeile">
<f:cObject typoscriptObjectPath="lib.ClassicParts"> Parts</f:cObject>
</f:section>
<f:section name="mainNavi">
<f:cObject typoscriptObjectPath="lib.mainMenu" />
</f:section>
<f:section name="subNavi">
<f:cObject typoscriptObjectPath="lib.subMenu" />
</f:section>
<f:section name="contentOben">
<f:format.raw>{contentOben}</f:format.raw>
</f:section>
<f:section name="contentLinks">
<f:format.raw>{contentLinks}</f:format.raw>
</f:section>
<f:section name="contentRechts">
<f:format.raw>{contentRechts}</f:format.raw>
</f:section>
<f:section name="footer">
<f:render partial="footer" arguments="{text: title}" />
<f:cObject typoscriptObjectPath="lib.metaFooterMenu" />
</f:section>
Meine Main.html ist ähnlich simpel:
<div class="container">
<div class="row header">
<div class="col-md-12 col-sm-12 col-xs-12 pull-right">
<div class="navbar-collapse collapse pull-right">
<f:render section="metaNavi" />
</div>
<div class="row">
<div class="col-md-2 col-sm-2 col-xs-2">
<f:render section="PageLogo" />
</div>
<div class="col-md-10 col-sm-10 col-xs-10 row">
<f:render section="titelzeile" />
<nav class="navbar navbar-default" role="navigation">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-main-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<div class="collapse navbar-collapse navbar-main-collapse">
<f:render section="mainNavi" />
</div>
</nav>
</div>
</div>
</div>
</div>
<div class="container main">
<div class="row">
<div class="col-md-3 col-sm-3 col-xs-5">
<f:render section="subNavi" />
</div>
<div class="col-md-9 col-sm-9 col-xs-7">
<f:render section="contentOben" />
<hr>
</div>
</div>
<div class="row margin_top_20">
<div class="col-md-7 col-md-offset-3 col-sm-6 col-sm-offset-3">
<f:render section="contentLinks" />
</div>
<div class="col-md-2 col-sm-3">
<f:render section="contentRechts" />
</div>
</div>
</div>
<div class="container footer_container">
<footer>
<f:render section="footer" />
</footer>
</div>
Nin habe ich für die beiden Platzhalter PageLogo, und Titelzeile, folgendes TS ausgelagert:
lib {
PageLogo = IMAGE
PageLogo {
file = GIFBUILDER
file {
XY = 300,30
backColor = #eeaaee
10 = TEXT
10.text.current = 1
10.fontColor = #ffffff
10.offset = 10, 25
}
}
ClassicParts = IMAGE
ClassicParts {
file = GIFBUILDER
file {
XY = 300,30
backColor = #cc0000
20 = TEXT
20.text.current = 1
20.fontColor = #ffffff
20.offset = 10, 25
}
}
}
Dies wird in meinem init.ts includiert:
<INCLUDE_TYPOSCRIPT: source="FILE: fileadmin/template/ts/logo.ts">
<INCLUDE_TYPOSCRIPT: source="FILE: fileadmin/template/ts/content.ts">
<INCLUDE_TYPOSCRIPT: source="FILE: fileadmin/template/ts/setup_xhtml_spamProtect.ts">
<INCLUDE_TYPOSCRIPT: source="FILE: fileadmin/template/ts/navigation.ts">
config {
doctype = html_5
#doctype = xhtml_trans
xhtml_cleaning = all
htmlTag_langKey = de
disablePrefixComment = 1
sendCacheHeaders = 0
removeDefaultJS = external
moveJsFromHeaderToFooter = 1
inlineStyle2TempFile = 0
}
[browser = msie]
config.doctypeSwitch = 1
[END]
tt_content.stdWrap.prefixComment >
lib.stdheader.stdWrap.prefixComment >
lib.stdheader.5.prefixComment >
page = PAGE
page {
10 = FLUIDTEMPLATE
10 {
file = fileadmin/template/fluid/default.html
partialRootPath = fileadmin/template/fluid/partials/
layoutRootPath = fileadmin/template/fluid/layouts/
variables {
pageTitle = TEXT
pageTitle.data = page:title
contentOben < styles.content.get
contentLinks < styles.content.getLeft
contentRechts < styles.content.getRight
}
}
}
page.includeCSS {
file1 = fileadmin/template/external/bootstrap_custom/css/bootstrap.min.css
file1.title = main_stylesheet
file2 = fileadmin/template/css/custom.css
file2.title = main_stylesheet
file2.media = screen
}
page.includeJS {
file1 = fileadmin/template/js/bootstrap.min.css
}
Nun zu dem sonderbaren Verhalten:
Setze ich in meiner Default.html für die section PageLogo folgendes:
<f:section name="PageLogo">
<f:cObject typoscriptObjectPath="lib.PageLogo">Logo1 Bild gerendert</f:cObject>
</f:section>
Wird nichts ausgegeben. Der DIV ist dann leer.
Gebe ich dort aber zum Beispiel
<f:section name="titelzeile">
<f:cObject typoscriptObjectPath="lib.ClassicParts">Parts</f:cObject>
</f:section>
aus, wird das Bild gerendert.
Nun versteh ich an dieser Stelle nicht, warum dass so ist, da doch beides eigentlich die gleichen Funktionen nur unter anderem Namen sind.