Re: [xsl] getting rid of xmlns

Subject: Re: [xsl] getting rid of xmlns
From: Jim_Albright@xxxxxxxxxxxx
Date: Sun, 27 Feb 2005 13:42:52 -0500
Thanks. 

copy-namespaces='no' 
works great. Problem solved. Sorry I forgot to say I am using XSLT 2.0.

Jim Albright
704 843-0582
Wycliffe Bible Translators

Date: Sun, 27 Feb 2005 03:15:02 -0000
To: <xsl-list@xxxxxxxxxxxxxxxxxxxxxx>
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Subject: RE: [xsl] getting rid of xmlns
Message-Id: <200502270315.j1R3FZo09975@xxxxxxxxxxxxxxxxxxxxxxx>

If the namespaces came from the stylesheet, use exclude-result-prefixes="w 
v
o" etc to avoid them finding their way into the result document.

If the namespaces came from the source document, use <xsl:element
name="{local-name()}" namespace="{namespace-uri()}"> in preference to
xsl:copy or xsl:copy-of. In XSLT 2.0 you can use xsl:copy-of select="XXX"
copy-namespaces="no" to copy an element except for any unused namespace
declarations.

Michael Kay
http://www.saxonica.com/ 

Current Thread