Search code examples
typo3typoscripttypo3-9.x

Typoscript condition with new symfony expression syntax


Anybody here who knows how to write this TS condition in the new symfony expression syntax?
[globalVar = TSFE:sys_page|versioningWorkspaceId = 1]

Or is there any other way to find out if one is viewing a workspace?

Thanks in advance!


Solution

  • the desired syntax is:

    [getTSFE().sys_page.versioningWorkspaceId == '1']

    As a rule of thumb, Arrays should be written with brackets, Objects are written with points.