Subject: Re: [xsl] QName as attribute value: save and clean up namespace declarations From: Martin Honnen <Martin.Honnen@xxxxxx> Date: Mon, 18 Jun 2012 14:00:00 +0200 |
in this example I have an order with different typed items. The type is a QName in an attribute. There are namespaces declared, having the same prefix as the 'prefix' in the xsi:type attribute. As you can see there are more namespaces declared as needed (whatever the reason for that case might be). Now I would like to clean up and just keep the ones that are 'used' in the xsi:type content. The stylesheet actually already does what I want, but I would like to know whether there might be a better way to do it, since it looks a little hackish to me.
<v:item xsi:type="ns4:lostItem" xmlns:ns1="http://prods.com/ns1" xmlns:ns2="http://prods.com/ns2" xmlns:ns3="http://prods.com/ns3">
<!--identity tranformation; do not copy namespaces; create namespace of xsi:type--> <xsl:template match="*[@xsi:type]">
Martin Honnen --- MVP Data Platform Development http://msmvps.com/blogs/martin_honnen/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] QName as attribute value:, G. Ken Holman | Thread | Re: [xsl] QName as attribute value:, David Carlisle |
Re: [xsl] QName as attribute value:, G. Ken Holman | Date | Re: [xsl] QName as attribute value:, David Carlisle |
Month |