Project

General

Profile

Actions

Bug #77714

closed

Warning missing in TS Object Browser/Template Analyzer when appending a TS condition with a string

Added by Oliver Schröder about 8 years ago. Updated over 4 years ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
TypoScript
Target version:
-
Start date:
2016-08-31
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
9
PHP Version:
7.0
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

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

Actions #2

Updated by Riccardo De Contardi about 8 years ago

  • Category changed from Backend User Interface to TypoScript
Actions #3

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.

Actions #4

Updated by Riccardo De Contardi over 5 years ago

I think it is still reproducible on 10.0.0-dev (latest master)

Actions #5

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: "_:-\." 
Actions #6

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

Actions #7

Updated by Frank Nägler almost 5 years ago

  • Assignee set to Frank Nägler
Actions #8

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

Actions #9

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

Actions #10

Updated by Frank Nägler almost 5 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #11

Updated by Benni Mack over 4 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF