Re: Wierd IE5B2

Subject: Re: Wierd IE5B2
From: Chris Maden <crism@xxxxxxxxxxx>
Date: Tue, 23 Feb 1999 11:07:18 -0500 (EST)
[Wendy Cameron]
> Regard IE5B2
> Well after many hours playing with Microsoft Examples I finally got
> <xsl:choose>
>    <xsl:when "test='something or other'">

YM <xsl:when test='something or other'>

And you need an end-tag for <xsl:when>.

>    </xsl:choose>

You could also use <xsl:if test="something else"> if you only wanted
to check one thing.

> And someone spoke of how match has less capabilites than select
> Can someone please explain how each of the following works? (Or is
> meant to work)
> match
> select
> test

test and select both take select patterns.  Select patterns have a
context, usually the node matched by the match pattern in the current

<xsl:template match="foo">
  <xsl:if test="bar">
    <xsl:text>This is used if foo has a child called bar.</xsl:text>

In this example, the context for <xsl:if>'s select pattern is the foo
element matched by the template's match pattern.  It would not be true
if there existed a bar anywhere; it has to be relative to the current

Match patterns succeed if they can be true from any context.  Once
upon a time, there were restrictions on match patterns; they were a
subset of select patterns.  But in the current draft, that restriction
was removed:

   [2] MatchExpr ::= SelectExpr

The lack of restriction has apparently made implementation more
difficult, and I have a feeling it may come back in some form, but I
can't be sure.

 not speaking in any way for the XSL WG or the W3C
<!ENTITY crism PUBLIC "-//O'Reilly//NONSGML Christopher R. Maden//EN"
"<URL> <TEL>+1.617.499.7487
<USMAIL>90 Sherman Street, Cambridge, MA 02140 USA" NDATA SGML.Geek>

 XSL-List info and archive:

Current Thread