Re: [xslt] Suppress namespace in output. Is it possible?

On 2005-01-10 14:08:41 -0800, Jia Pu wrote:
> I am trying to use xsl:copy a tree to output. It seems that the xslt
> processor will automatically add the xmlns attribute in the output.
> For exmaple, source tree:
> <rule id="Digits">
> </rule>
> will turn into:
> <rule xmlns=""; id="Digits">
> </rule>
> Is it possible to suppress that behavior so that the output is exactly
> same as the input?

If you want to change the namespace (e.g. from
""; to the null namespace),
then you can't say that the output is the same. The XSLT
processor just makes sure that the namespace is correct by
adding the xmlns attribute.

The context (e.g. the default namespace) is important, and you
didn't say anything about it.

Vincent Lefèvre <vincent vinc17 org> - Web: <>
100% accessible validated (X)HTML - Blog: <>
Work: CR INRIA - computer arithmetic / SPACES project at LORIA

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]