Subject: RE: [xsl] Copy namespace definition to the result tree using xslt From: Kishorerc@xxxxxxxxxxx Date: Tue, 13 Mar 2001 02:46:38 -0800 |
Hi Mike, Is there no way I can output the element as <xsd:schema xmlns:xsd="http://www.w3.org/1999/XMLSchema"> instead of just <xsd:schema>. I understand that it is redundant and hence it does not output the xmlns attribute. But it is required for the application I am working on. I also tried adding the xmlns attribute using <xsl:attribute> element but even the the transformer does not output the xmlns attribute. It seems that xmlns is a reserved attribute or QName and hence the transformer ignores it. Any ideas??? Thanks Kishore -----Original Message----- From: Michael Kay [mailto:mhkay@xxxxxxxxxxxx] Sent: Tuesday, March 13, 2001 2:00 AM To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: RE: [xsl] Copy namespace definition to the result tree using xslt > I am not able to output the namespace definition to the result tree. > > The EXPECTED OUTPUT file from the XSLT file should look like this: > <?xml version="1.0" encoding="UTF-8"?> > <transactions xmlns:xsd="http://www.w3.org/1999/XMLSchema"> > <mytesting> > <xsd:schema > xmlns:xsd="http://www.w3.org/1999/XMLSchema"> > <-- problem line I don't see anything in your XSLT that outputs the <transactions> element, but never mind. The xmlns:xsd declaration on your <xsd:schema> element is completely redundant according to the XPath data model (you get the same XPath tree whether it is there or not) and therefore an XSLT processor will not normally generate it. Mike Kay Software AG XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Copy namespace definition, Michael Kay | Thread | Re: [xsl] Copy namespace definition, David Carlisle |
Re: [xsl] mismatched tags with xsl:, Jonathan Cates | Date | RE: [exsl] rationale (Was: Re: [xsl, DPawson |
Month |