tiaxgame
{% set data='a/b/c'|split('/') %}
{% set i=1 %}
{{data[i]}}
I want output = "b" (with 'var name' "i")
Graham
tiaxgame That code already works the output is "b" !
or do you want to output it like "b[1]"
{{data[i]}}[{{i}}]
or "b[i]"
{{data[i]}}[i]
tiaxgame
Graham I want creat a "loop" with tag 'for' as 'xtscript'
But i'm not know,
{% set i=0 %}
{% for ??? %}
{% set i %>{{i+1}}{% endset %}
{{i}}
If i>10
Stop
Endif
Endfor
tiaxgame
Graham i want to change 'string' -> "number"
{% set a="2" %}
{{a+1}}
I want: output = 3 (the number)
tiaxgame
Graham Ok.
I want to used 'encode' and 'decode' of "base64"
, "chr", "sha1", ... etc.
Graham
tiaxgame I do not think twig has those functions