Anna Afonchenko wrote:
Even if the white spaces are supressed, the algorythm will stay right,
because algorythm should check all a tags that are followed by another a tag,
and the only node between them MAY (not MUST) be white-space only text node.
The problem is here
  select="//a[name(following-sibling::node()[1][not(self::text() and
                                      ^^^^^ You select the following nodes
                                            including all text nodes
                                            ^^^^ The grab the first.
For these two nodes in the source:
 <a href="one.html">One</a>  <a href="two.html">Two</a>
MSXML gets the second <a> element node, because it strips the text
node with the space between the two <a> elements. All other
processors see this text node instead of the second <a> node at this
point and the whole select turns out empty.

Add a
 <xsl:strip-space elements="*"/>
to the beginning of your style sheet in order to get the same results
for all processors.
Alternatively, try
 select="//a[following-sibling::a[1][not(normalize-space())]"
but perhaps you even want
 select="//a[following-sibling::a[not(normalize-space())][1]"
instead.

BTW you should ask XSLT questions on the XSLT list:
 http://www.mulberrytech.com/xsl/xsl-list/

J.Pietschmann


---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>

Reply via email to