You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xalan.apache.org by Chris Simmons <cp...@decisionsoft.com> on 2008/01/07 11:33:11 UTC
Redundant xmlns:xml namespace bindings.
Hi,
I'm using the DOM 3 serializer in Xalam. Actually, its the one now
packaged with Xerces since they deprecated their own serializers. I've
found that this serializer adds xmlns:xml namespace bindings all the
while. Now this is not just wasteful its rather bad from a
compatibility point of view since MSXML seems to treat an explicit
binding of this prefix as an error! If you don't believe me try viewing
https://issues.apache.org/jira/secure/attachment/12371800/boundxmlprefix.xml
in IE.
Needless to say we're keen on getting this fixed ASAP since its causing
problems for our clients using Microsoft based tools. I've already
attached a test and patch to fix the bug, so I'd appreciate it if
somebody could have a look. Its literally a one line fix.
https://issues.apache.org/jira/browse/XALANJ-2409
Cheers,
Chris Simmons.
Re: Redundant xmlns:xml namespace bindings.
Posted by Chris Simmons <cp...@decisionsoft.com>.
keshlam@us.ibm.com wrote:
>
> 1) The explicit binding of the xml: prefix *should* be occurring only
> on the root element; once it's in scope, additional declarations
> shouldn't be being produced. You might want to post enough code that
> people can reproduce your problem for study.
>
> 2) Rejecting redundant declarations of the xml: prefix is Just Plain
> Wrong, if they're using the correct URI. I'd suggest lighting a large
> fire under Microsoft about that one.
>
> ______________________________________
> "... Three things see no end: A loop with exit code done wrong,
> A semaphore untested, And the change that comes along. ..."
> -- "Threes" Rev 1.1 - Duane Elms / Leslie Fish
> (http://www.ovff.org/pegasus/songs/threes-rev-11.html)
>
1) This is true but it shouldn't be necessary to bind it at all.
Typically the xml:lang attribute wasn't occurring on the root element
but thousands of other descendant elements so until we added a
work-around that added the binding explicitly at the root we had
thousands of xmlns:xml bindings.
2) I don't disagree :) but they I can't fix MSXML...
Re: Redundant xmlns:xml namespace bindings.
Posted by ke...@us.ibm.com.
1) The explicit binding of the xml: prefix *should* be occurring only on
the root element; once it's in scope, additional declarations shouldn't be
being produced. You might want to post enough code that people can
reproduce your problem for study.
2) Rejecting redundant declarations of the xml: prefix is Just Plain Wrong,
if they're using the correct URI. I'd suggest lighting a large fire under
Microsoft about that one.
______________________________________
"... Three things see no end: A loop with exit code done wrong,
A semaphore untested, And the change that comes along. ..."
-- "Threes" Rev 1.1 - Duane Elms / Leslie Fish
(http://www.ovff.org/pegasus/songs/threes-rev-11.html)