I\'m reasonably new to xlst and am confused as to whether there is any way to store a value and change it later, for example incrementing a variable in a loop.
I\'m
XSLT is a functional language and among other things this means that variables in XSLT are immutable and once they have been defined their value cannot be changed.
Here is how the same effect can be achieved in XSLT:
when this transformation is applied on the following XML document:
the result is:
$i = 1
$i = 2
$i = 3
$i = 4
$i = 5