[TYPO3-project-4-3] Variation for TypoScript "if"

Martin Kutschker masi-no at spam-typo3.org
Wed Jun 10 12:05:40 CEST 2009


Ernesto Baschny [cron IT] schrieb:
> Hi,
> 
> maybe some more usual way of expressing a condition would fit better the
> understanding?
> 
> if = $a > $b
> if.a =
> if.b =
> 
> if = ( $a AND $b ) OR ( $c and $d )
> if.a =
> if.b =
> if.c =
> if.d =

That's of course possible too. I would only use a syntax that fits more
into the existing marker replacements (constants and dataWraps).


> And also having some basic functions:
> 
> if = CONTAINS($a, "xyz")
> if.a = ...

Makes it a bit hard to parse and perhaps to slow in production. A
cheaper version could look like this:

if = {expr}
if.expressions.a = contains
if.expressions.a.haystack =
if.expressions.a.needle =

Masi


More information about the TYPO3-project-4-3 mailing list