Tipps & Tricks
Allerlei zum Thema TYPO3 NEOS.
Cache löschen
Normal, d.h. im Development Modus:
./flow flow:cache:flush
Für Production Umgebung:
FLOW_CONTEXT=Production ./flow flow:cache:flush
Layout
NodeTypes
Um der Seite ein Layout zuzuordnen folgendes in Configuration/NodeTypes.yaml einfügen:
##
# Adjust the "Page" node type:
# Add two properties "layout" and "subpageLayout" to the default "Page" NodeType
#
'TYPO3.Neos.NodeTypes:Page':
childNodes:
'teaser':
type: 'TYPO3.Neos:ContentCollection'
properties:
'layout':
ui:
inspector:
editorOptions:
values:
'default':
label: 'Default'
'landingPage':
label: 'Landing page'
'subpageLayout':
ui:
inspector:
editorOptions:
values:
'default':
label: 'Default'
'landingPage':
label: 'Landing page'
TypoScript
In Root.ts2
default < page
// Special page layout with less navigation components
landingPage < page
landingPage.body {
// Hide breadcrumb on landing pages
parts.breadcrumb >
landingPage = ${true}
}
Optional kann man dem Body Tag eine andere id zuordnen:
landingPage.bodyTag.attributes.id = 'landingpage'
Fluid Template
Im Template kann man dann unterscheiden:
<f:if condition="{landingPage}">
...
</f:if>