Subject: [xsl] xsl templates, Removing spurious namespace declarations in output elements From: "Tim Wilkins" <Tim.Wilkins@xxxxxxxxxxxxxxxx> Date: Tue, 8 Apr 2003 18:43:29 +0100 |
I require as final output an XML file without any use of namespaces. The input data does make use of namespaces, although this is part of a multiple pass operation and I have elements which don't use namespaces by this stage. I wish to copy some of these elements without changing them, and have tried, for example <xsl:template match="Attribute"> <xsl:copy-of select="current()"/> </xsl:template> The template copies the elements as required, except that I get spurious namespace declarations such as "xmlns:gml="http://www.opengis.net/gml" in the output (as attributes on the "Attribute" output element), even though the xsl:stylesheet specifically excludes them (using exclude-result-prefixes). How do I get rid of them? My guess is that, since I'm trying to copy an element without a namespace it is assuming that any could apply, but in this case none do (the output uses a DTD). I also get namespace declarations from the input file, not mentioned by the style sheet, and I wish to exclude these as well, without making the stylesheet depend upon these. Thank you, Tim Wilkins XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] 10,000 document()'s, S Woodside | Thread | Re: [xsl] xsl templates, Removing s, David Carlisle |
RE: [xsl] 10,000 document()'s, cknell | Date | Re: [xsl] xsl templates, Removing s, David Carlisle |
Month |