Bug #77714
closedWarning missing in TS Object Browser/Template Analyzer when appending a TS condition with a string
100%
Description
Prepending a Typoscript condition with a string (like x[globalVar = GP:test = 1]) shows warnings in both the Typoscript Object Browser and Template Analyzer (x[globalVar = GP:test = 1] - ERROR: Line 322: Object Name String, "x[globalVar" contains invalid character "[". Must be alphanumeric or one of: „:-\.“_) and this broken condition is not listed as a condition underneath the TS tree in the TS Object Browser.
But appending a Typoscript condition with a string (like [globalVar = GP:test = 1]x) does not show warnings in neither the Typoscript Object Browser not the Template Analyzer and this broken condition is listed as a condition underneath the TS tree in the TS Object Browser. (As in my case the string was an invisible UTF-8 character the TS Object Browser condition looked perfectly ok, but wasn’t.)
I could reproduce the problem in Typo3 4.5.40, 7.6.9 und 8.3.0.
Files
Updated by Oliver Schröder about 8 years ago
Updated by Riccardo De Contardi about 8 years ago
- Category changed from Backend User Interface to TypoScript
Updated by Riccardo De Contardi almost 6 years ago
The issue is still present on 9.5.2-dev (latest master).
I am wondering how this could be solvable, as characters after the condition must be allowed (operators - see https://docs.typo3.org/typo3cms/TyposcriptReference/Conditions/Syntax.html#trimming-braces-and-condition-operators), it should be a check for specific strings of characters like "&&
", "||
", "AND
", "OR
"
but also
[dayofmonth = 9][month = 5]
should be allowed . also spaces must be taken in account.
Updated by Riccardo De Contardi over 5 years ago
I think it is still reproducible on 10.0.0-dev (latest master)
Updated by taywa gmbh over 5 years ago
- TYPO3 Version changed from 8 to 9
I use this in TYPO3 LTS 9
[{$taywa.config.login.use} == 1] @import /fileadmin/Resources/Private/Typoscripts/Lib/login.ts [end]
shows this, even if this should be valid
Object Name String, "["" contains invalid character "[". Must be alphanumeric or one of: "_:-\."
Updated by Gerrit Code Review almost 5 years ago
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/63092
Updated by Gerrit Code Review almost 5 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/63092
Updated by Gerrit Code Review almost 5 years ago
Patch set 1 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/63112
Updated by Frank Nägler almost 5 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 10b6c5e864b3b1c730ead35d038fe0ca54da1ce4.