Also note that besides the ternary operator you can also use the "reverse" condition syntax, just like perl... e.g. [$ SET n = 0 IF z = 1 %] is valid TT syntax.[% x = f( z == 1 ? 0 : 1 ) %]
In reply to Re: Template Toolkit, Default and Zero
by davidrw
in thread Template Toolkit, Default and Zero
by marvell
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |