Re: [xsl] create escaped(?) html of some nodes

Subject: Re: [xsl] create escaped(?) html of some nodes
From: Florent Georges <darkman_spam@xxxxxxxx>
Date: Wed, 11 Oct 2006 19:05:08 +0200 (CEST)
Jan Limpens wrote:


> 2 looks very nice as I can use it in many places. I just don't
> understand - how does the node-set() function come into play

  You can dig the archive for "micro-pipelining".  The
concept is very simple: you construct some result, but this
is not the final result, you apply some transformations on
it.  In this case, you construct HTML then you apply
templates that serialize the tree to a string.

  In XSLT 2.0, no problem.  All this is standard.  In XSLT
1.0, when you construct the result, you don't get a
node-set, but a result tree fragment.  It is similiar to a
node-set, but with limitations.  For example, you cannot
apply templates to it.

  Fortunately, all known XSLT 1.0 implementation  (but the
one in FF) provide an extension function, named node-set()
(in different namespaces) to get a node-set from an RTF.  So
if you are using XSLT 1.0, you put the result (the RTF) you
construct in a variable, then:





Yahoo! Mail riinvente le mail ! Dicouvrez le nouveau Yahoo! Mail et son interface rivolutionnaire.

Current Thread