Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
2.7.1
-
None
-
Security Level: No security risk; visible to anyone (Ordinary problems in Xalan projects. Anybody can view the issue.)
-
None
-
WinXP, java 1.6.0_07 testing with xalanj in custom java as well as in Oxygen 9 XSLT Debugger
Description
test case:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:template match="top">
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="middle">
<xsl:number format="1" from="top" level="any" count="bottom"/>
</xsl:template>
</xsl:stylesheet>
<?xml version="1.0" encoding="UTF-8"?>
<top>
<middle>
<test><bottom/><bottom/></test>
</middle>
<middle/>
</top>
The output is correctly
0
2
However, if the xml is changed so that the first /middle tag is at the end of the line rather than on a new line of it's own
<top>
<middle>
<test><bottom/><bottom/></test></middle>
<middle/>
</top>
The output becomes
0
0
It appears that it does not count the two bottom tags if the /middle tag is on the end of the line. I tried this with multiple other sets of markup and the results are the same.
Attachments
Attachments
Issue Links
- is related to
-
XALANC-683 xsl:number with level any does not always count all of the preceeding nodes in the document.
- Resolved