Visit Mozilla.org

XSLT:choose

Un article de MDC.

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

Sommaire

L'élément <xsl:choose> définit un choix parmi un certain nombre d'alternatives. Il se comporte comme l'instruction switch d'un langage procédural.

[modifier] Syntaxe

<xsl:choose>
	<xsl:when>
	<xsl:otherwise> [optionnel]
</<xsl:choose>

[modifier] Attributs obligatoires

Aucun.

[modifier] Attributs optionnels

Aucun.

[modifier] Type

Instruction, apparaît dans un modèle. Il contient un ou plusieurs éléments <xsl:when>, et éventuellement un élément final <xsl:otherwise>.

[modifier] Définition

XSLT 1.0, section 9.2.

[modifier] Support Gecko

Supporté.