<xsl:if>
The if statement is Necessary when you want to test if a sequence is empty or not.
<xsl:if test="expression">
...some output if the expression is true...
</xsl:if>
...some output if the expression is true...
</xsl:if>
<xsl:choose>
<xsl:choose>
<xsl:when test="expression">
... some output ...
</xsl:when>
<xsl:otherwise>
... some output ....
</xsl:otherwise>
</xsl:choose>
<xsl:when test="expression">
... some output ...
</xsl:when>
<xsl:otherwise>
... some output ....
</xsl:otherwise>
</xsl:choose>
<xsl:for-each>
<xsl:for-each select="expression">
... some output ...
</xsl:for-each>
... some output ...
</xsl:for-each>
Sequences of integers with to operator
You can create an integer sequence with the to operator
1 to 5
<xsl:for-each select="1 to 5"><br /></xsl:for-each>
Filtering illegal characters
Some characters needs to be escape
Greater than( > ) needs to be escaped as >
Less than( < ) needs to be escaped as <