[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Future XSLT expansion.

Subject: RE: Future XSLT expansion.
From: "Jonathan Borden" <jborden@xxxxxxxxxxxx>
Date: Sat, 18 Mar 2000 14:04:26 -0500
jon borden
Jon Smirl wrote:
>
> Am I experiencing a side effect of this discussion?
>
> I would like to do this:
>
> <xsl:variable name="foo">
>     <mytag>
>         data
>     </mytag>
> </xsl:variable>
>
> <xsl:apply-templates select="$foo"/>

Yes, this is a real issue. xsl:variable produces a Result-Set NOT a
Node-Set. One could argue that it ought produce a node-set, but that is how
the spec reads. I believe that this is why result-set -> node-set 'extension
converters' exist, but haven't personally needed to use them.

>
> This gives me a "cannot convert to node-set error" with XT.
> It was my understanding that this was in XSLT to prevent
> feedback from the resultset back into the input of the pattern
> matches.
>
> Instead I use:
>
> <mydata>
>     <mytag>
>         data
>     </mytag>
> </mydata>
>
> <xsl:apply-templates select="document('')/mydata"/>

	why not: <xsl:apply-templates select="document('data.xml')/mydata" />? I
would argue that it is 'cleaner' to factor data out of the transform sheet
itself, but regardless it also avoids the double parse issue.

>
> BTW - the Release 3 of the Microsoft XML dll allows the
> first case so it is in disagreement with JClark's XT.
>

	This is a known area of MSXML non-conformance. JClark's XT and Xalan (BTW)
are correct.

Jonathan Borden


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.