You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by bu...@apache.org on 2002/11/22 15:03:00 UTC
DO NOT REPLY [Bug 14767] New: -
Cannot bind "http://www.w3.org/XML/1998/namespace" to a prefix other than "xml"
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14767>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14767
Cannot bind "http://www.w3.org/XML/1998/namespace" to a prefix other than "xml"
Summary: Cannot bind "http://www.w3.org/XML/1998/namespace" to a
prefix other than "xml"
Product: Xerces2-J
Version: 2.2.0
Platform: All
OS/Version: All
Status: NEW
Severity: Blocker
Priority: Other
Component: Other
AssignedTo: xerces-j-dev@xml.apache.org
ReportedBy: dims@yahoo.com
To recreate the problem, just run "java dom.Writer ns.xml". I get the following
error:
[Fatal Error] ns.xml:6:69: The prefix "xml" cannot be bound to any namespace
other than its usual namespace; neither can the namespace for "xml" be bound to
any prefix other than "xml".
Where does it say (in any spec) that this is an error? How can i keep namespace
support but not run into this problem?
I can also recreate the problem using the following code. FYI, This problem does
not show up with the parser that is in JDK14.
DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
factory.setNamespaceAware(true);
DocumentBuilder builder = factory.newDocumentBuilder();
System.out.println("Parsing : " + args[0]);
Document doc = builder.parse(new File(args[0]));
Thanks,
dims
================================ ns.xml =========================
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:nsxml="http://www.w3.org/XML/1998/namespace"
>
</wsdl:definitions>
===================================================================
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-dev-help@xml.apache.org