RE: [xslt] Suppress namespace in output. Is it possible?
- From: "Jia Pu" <JiaPu LumenVox com>
- To: "'The Gnome XSLT library mailing-list'" <xslt gnome org>
- Subject: RE: [xslt] Suppress namespace in output. Is it possible?
- Date: Mon, 10 Jan 2005 15:57:23 -0800
Ok, let me re-state the question.
I understand the importance of keeping namespace around. However in this
particular case, I only want the output *looks* as same as the input. In
this application, I copy the source tree to output for nothing but a
reference. So that people who look at the transformed output can tell where
the output was transformed from.
Is there anyway to achieve that, other than write my own copy template?
>From: xslt-bounces gnome org [mailto:xslt-bounces gnome org]
>On Behalf Of Vincent Lefevre
>Sent: Monday, January 10, 2005 3:42 PM
>To: xslt gnome org
>Subject: 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">
>> will turn into:
>> <rule xmlns="http://www.w3.org/2001/06/grammar" id="Digits">
>> Is it possible to suppress that behavior so that the output
>> same as the input?
>If you want to change the namespace (e.g. from
>"http://www.w3.org/2001/06/grammar" 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: <http://www.vinc17.org/>
>100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/>
>Work: CR INRIA - computer arithmetic / SPACES project at LORIA
>xslt mailing list, project page http://xmlsoft.org/XSLT/
>xslt gnome org
] [Thread Prev