xsl-list
[Top] [All Lists]

Re: [xsl] grouping based on string but with child nodes

2008-10-13 11:34:25
On Mon, Oct 13, 2008 at 16:17, Andrew Welch 
<andrew(_dot_)j(_dot_)welch(_at_)gmail(_dot_)com> wrote:

Yes, use 2 passes, it will help you diagnose problems in the 2nd pass
much more easily.

The first pass is an idenity transform with:

<xsl:template match="title">
 <xsl:for-each select="tokenize(., '||')>
   <title><xsl:value-of select="."/></title>

Hiya Andrew,

Thanks for your suggestion, but it isn't going to work.  tokenize()
treats the node like a string and so gets rid of any embedded markup.
I.e. the <emph> (and very occasionally other) elements.

For the second pass it's not clear to me how you want to group them,
so maybe post back with an example if you need to.

I wanted to end up with the same kind of output that tokenize() would
give me, but preserving any embedded markup as well.

-James

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--