XML & XSL - xsl:when


Multiple conditional testing in conjunction with the xsl:otherwise and xsl:choose.

Syntax

<xsl:when expr="script-expression" language="language-name" test="pattern">

Attributes

Parent Elements

Child Elements

Purpose

One of the alternatives to be chosen by the xsl:choose. The alternative is xsl:otherwise element.

Use the xsl:if for simple conditional testing.

Global Population Extraction Example

Click here to view an example.