[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] XSLT and XML in the same document


Subject: Re: [xsl] XSLT and XML in the same document
From: "M. David Peterson" <m.david@xxxxxxxxxxxxx>
Date: Sun, 27 May 2007 15:57:52 -0600

On Sun, 27 May 2007 15:39:05 -0600, David Carlisle <davidc@xxxxxxxxx> wrote:

which should also work in opera, just beware of white space parsing
differences (which can be avoided with xml:space) when parsing a
document as part of the stylesheet .

Ooh... Good catch, David!


The caveats with EXSLT node-set[1] from a browser perspective are fairly well documented on this list, so I won't go into extended detail, but Firefox 3.0 and Opera both support it, and IE 5.x+ supports the same basic functionality via msxsl:node-set()[2]. Kind of a pain to work between the two of them inside of the same transformation file, but a simple check using function-available or by comparing the value returned by system-property('xsl:vendor') will allow you to quickly and easily adapt your transformations according the the proper usage of node-set for each processor.

Of course, I still haven't check to see if Safari brought any of the support for EXSLT from libxslt when they did the integration a few years back. I'll check that now and report back.


[1] http://exslt.org/exsl/functions/node-set/index.html [2] http://msdn2.microsoft.com/en-us/library/hz88kef0(vs.71).aspx

--
/M:D

M. David Peterson
http://mdavid.name | http://www.oreillynet.com/pub/au/2354 | http://dev.aol.com/blog/3155



Current Thread