xsl-list
[Top] [All Lists]

xsl:call-template , strange behaviour

2005-06-05 21:01:14
I have written this stylesheet -

<?xml version="1.0"?> 
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; 
                xmlns:temp="http://whatever"; 
                version="2.0">
 
 <xsl:output method="xml" indent="yes" /> 

 <xsl:template match="/">
    <xsl:call-template name="test" />
    <xsl:call-template name="temp:test" />
 </xsl:template>

 <xsl:template name="test">
   <a/>
 </xsl:template>
 
 <xsl:template name="temp:test">
   <b/>
 </xsl:template>
 
</xsl:stylesheet>

With both Xalan-J 2.6 and Saxon 8.4, I get the output
-
<?xml version="1.0" encoding="utf-8"?>
<a xmlns:temp="http://whatever"/>
<b xmlns:temp="http://whatever"/>

I am curious, why element <a> gets associated with the
namespace 'temp' ..?

Regards,
Mukul



__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

--~------------------------------------------------------------------
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>
--~--