DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=13304>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=13304

Empty string URI reference in xsl:attribute

           Summary: Empty string URI reference in xsl:attribute
           Product: XalanJ2
           Version: 2.4
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Xalan-Xsltc
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


Empty string URI reference in xsl:attribute
According to 7.1.3 Creating Attributes with xsl:attribute
"The string that results from instantiating it should be a URI reference �  If 
the string is empty, then the expanded-name of the attribute has a null 
namespace URI."

test-case -

<?xml version="1.0"?>
<docs>
  <a a_XX="">Attr0</a>
</docs>

<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version="1.0"
      xmlns:ped="my_space">
<xsl:template match="/">
  <Out>
        <xsl:attribute name="{docs/a}" 
namespace="{docs/a/@a_XX}">AA</xsl:attribute>
  </Out> 
</xsl:template>
</xsl:stylesheet>

Output XSTL is correct
<?xml version="1.0" encoding="UTF-8"?>
<Out xmlns:ped="my_space" Attr0="AA"/>

Output XSTL is incorrect
<?xml version="1.0" encoding="UTF-8"?>
<Out xmlns:ped="my_space" xmlns:ns0="" ns0:Attr0="AA"/>

Reply via email to