Project

General

Profile

Actions

Bug #98588

open

Condition for colpos not working in PageTSConfig

Added by Bernhard Eckl over 1 year ago. Updated over 1 year ago.

Status:
New
Priority:
Should have
Assignee:
-
Category:
TypoScript
Target version:
-
Start date:
2022-10-12
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
10
PHP Version:
7.4
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

The following condition does not work (tested in TYPO3 10 and 11):

[request.getQueryParams()['defVals']['tt_content']['colPos'] == 3]
TCEFORM.tt_content.header_layout.removeItems = 1,2,6,8,9,10
[end]

But it should according to:
https://forge.typo3.org/issues/91646
https://wiki.sebkln.de/doku.php?id=typo3:about:conditions

Is there another syntax to query the colpos?

Actions #1

Updated by Christoph Lehmann over 1 year ago

Does traverse() solve it for you?

This works

[traverse(request.getQueryParams(), 'defVals/tt_content/sys_language_uid') == 0]
TCEFORM.tt_content.header.disabled=1
[end]

When using traverse() you also don't get undefined key warnings in newer PHP versions.

See https://docs.typo3.org/m/typo3/reference-typoscript/main/en-us/Conditions/Index.html#traverse

Actions

Also available in: Atom PDF