witrin
witrin

Reputation: 3763

Apply additional TypoScript template to root page only

I have a root page with two TypoScript templates in this order:

  1. Root Template (the root template)
  2. Additional Template (a non root template)

My problem is the second template is ignored. I just want that the second template applies to the root pages only. How would this be possible, without linking the root page to a subpage or using conditions?

Upvotes: 0

Views: 886

Answers (2)

Urs
Urs

Reputation: 5122

For the record - here's the condition that does this too (although OP said without conditions):

[treeLevel = 0]
[global]

Can be helpful sometimes, as there is no hasPid condition, only pidInRootlineand pidUpInRootline

Upvotes: 1

biesior
biesior

Reputation: 55798

Create templates records (let's say main and subpages) NOT in the root page but for an example in sys folder.

On main page create additional template, include main and at Options tab set subpages in Template on next level field.

enter image description here

Upvotes: 3

Related Questions