Visit Mozilla.org

XSLT:when

Un article de MDC.

Référence XSLT/XPath : Éléments XSLT, Fonctions EXSLT, Fonctions XPath, Axes XPath

Sommaire

L'élément <xsl:when> apparaît toujours dans un élément <xsl:choose>, et se comporte comme une structure conditionelle 'case'.

[modifier] Syntaxe

<xsl:when test=EXPRESSION>
	MODÈLE
</xsl:when>

[modifier] Attribut obligatoire

test
Définit une expression booléenne à évaluer. Si elle est vraie, le contenu de l'élément est exécuté ; sinon, il est ignoré.

[modifier] Attributs obligatoires

Aucun.

[modifier] Type

Sous-instruction, apparaît toujours dans un élément <xsl:choose>.

[modifier] Définition

XSLT 1.0, section 9.2.

[modifier] Support Gecko

Supporté.