Re: [xsl] Accessing text between nodes

Subject: Re: [xsl] Accessing text between nodes
From: "Thomas B. Passin" <tpassin@xxxxxxxxxxxx>
Date: Wed, 27 Jun 2001 13:06:29 -0400
I was running it from Cooktop, i.e., basically the same as from the command
line, I believe.  And I see that text()[2] worked with msxml3.

All this just goes to show that you don't want to rely on exact placement of
nodes, nor of the presence or absence of whitespace, if you can avoid it.
Just reinforcing old lessons, I guess.


Tom P

[Michael Kay]

> > Conversely, if you added some more text within <Node> after
> > those <SubNode>
> > elements, text() does not get the added text.  text()[3] does
> > get that added
> > text, though (text()[2] gets whitespace). That's with saxon,
> > msxml3 returns
> > nothing for text()[3].  Hmm - Mike, which one is right (it
> > must be saxon!)?
> >
> MSXML3 handles whitespace correctly if you take the trouble to build the
> with the preserveWhitespace property set to true. By default, it strips
> whitespace nodes before the XSLT engine gets to see them.

 XSL-List info and archive:

Current Thread