[jdom-interest] unwanted namespace attributes
Michael Kay
mike at saxonica.com
Tue Oct 17 07:52:59 PDT 2006
> I am using the XMLOutputter to capture in a String the output
> of an element with all its sons. The original XML has an
> element like this
>
> <BODY:CBIHdrBdyInv>
>
> which gets printed as
>
> <BODY:CBIHdrBdyInv xmlns:BODY="urn:CBI:xsd:CBIBdySrvInv.001.01">
>
> The same thing happens to other tags as well. I tried both
> passing a Raw Format to the XMLOutputter constructor and
> without any format but didn't work. Should I set something to
> avoid it?
Why would you want to avoid it? Surely if the element name has the namespace
prefix "BODY", the recipient needs to know what namespace URI this is
referring to?
Or are you trying to transform the data so it is in a different namespace?
Michael Kay
http://www.saxonica.com/
More information about the jdom-interest
mailing list