I'm new to XML parsing. I'm having a problem where I ouput a DOM document using an identity transformer and for some reason the namespace URI's are missing.
I'm using
Java 1.4.1_03. If I add the jars from the latest version of xalan to the classpath, I get my URIs. The problem is that because this is going onto a webserver running a lot of legacy code, they will not allow me to load xalan (and the latest xercesImpl.jar, etc) because of the risk of impacting the existing applications.
I figure there is some feature I have to set, or something else small I'm missing to get the transformer to output the namespace URIs.
I wrote a little
test program to demonstrate the problem (see the end of the post). Below is the output from two runs of that test program. The first is with the xalan jars in the classpath. The second is without the xalan jars in the classpath. Notice the namespace URIs disappear. Is there someway, without using the xalan package, I can get the transformer to output the namespace URIs?
With xalan (namespace URIs are present) Without xalan (namespace URIs are missing) Test program [ August 08, 2006: Message edited by: Todd Johnson ]