Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- namespace: TypoScript=TYPO3.TypoScript
- /**
- * Root TypoScript template for the testsite Site
- */
- page = Page {
- head {
- stylesheets = TypoScript:Template
- stylesheets {
- templatePath = 'resource://sesc.testsite/Private/Templates/Page/Default.html'
- sectionName = 'stylesheets'
- }
- scripts = TypoScript:Template
- scripts {
- templatePath = 'resource://sesc.testsite/Private/Templates/Page/Default.html'
- sectionName = 'scripts'
- }
- titleTag {
- // Overwrite the title tags content with a collection to create a breadcrumb
- content = TYPO3.TypoScript:Collection {
- // Retrieve all parent document nodes excluding the homepage
- collection = ${q(documentNode).add(q(documentNode).parents()).slice(0, -1).get()}
- itemName = 'node'
- iterationName = 'nodeIterator'
- // Implode node titles with a dash
- itemRenderer = ${q(node).property('title') + (nodeIterator.isLast ? '' : ' - ')}
- // Always add general site name as suffix
- @process.siteName = ${(value ? value + ' - ' : '') + 'Honig-Welten'}
- }
- }
- }
- // This query checks if the second level menu has items and sets an additional class for the body
- bodyTag.attributes.class = ${q(node).parents().count() >= 1 && q(node).children('[instanceof TYPO3.Neos:Document]').filter('[_hiddenInIndex=false]').count() > 0 ? 'has-subpages' : ''}
- body {
- templatePath = 'resource://sesc.testsite/Private/Templates/Page/Default.html'
- sectionName = 'body'
- parts {
- menu = Menu {
- entryLevel = 1
- maximumLevels = 3
- }
- breadcrumb = Breadcrumb
- }
- // These are your content areas, you can define as many as you want, just name them and the nodePath.
- content {
- teaser = ContentCollection {
- nodePath = 'teaser'
- }
- // Default content section
- main = PrimaryContent {
- nodePath = 'main'
- }
- }
- footer = TYPO3.Neos:ContentCollection {
- nodePath = ${q(site).find('footer').property('_path')}
- collection = ${q(site).children('footer').children()}
- }
- }
- }
- default < page
- landingPage < page
- landingPage.body {
- templatePath = 'resource://sesc.testsite/Private/Templates/Page/LandingPage.html'
- }
Advertisement
Add Comment
Please, Sign In to add comment