[SoapRMI] preserving prefixes in document fragments
Andy Harrison
andyh_at_agaricus.co.uk
Fri, 16 Feb 2007 11:25:18 +0000
Aleksander Slominski wrote:
> Andy Harrison wrote:
>> What I want to know is, is it possible to get the
>> builder.serializeToXxxxx functions to not invent their own prefixes and
>> use the prefixes that are already loaded??
>>
> what version of xpp3 did you use? i remember bug like that in past and
> it may be fixed in the latest version.
I was using version 3-1.1.3.4M, I've just upgraded to 3-1.1.4c but it
makes no difference.
I did find an interesting thing, if I just change back the prefixes from
ns1: to o: then it works again. MS Word is ignoring the locally declared
namespaces altogether and is looking for the prefix "o". Forget that
"n1" is just the same namespace....
FAILS (n1 prefix not o)
<v:shape adj="0,,0" coordsize="" id="_x0_0_180_240.0094"
n1:spid="_x0000_s1026" n1:spt="100" path="" style="blah blah"
xmlns:n1="urn:schemas-microsoft-com:office:office"
xmlns:v="urn:schemas-microsoft-com:vml">
WORKS (back to o prefix)
<v:shape adj="0,,0" coordsize="" id="_x0_0_180_240.0094"
o:spid="_x0000_s1026" o:spt="100" path="" style="blah blah"
xmlns:o="urn:schemas-microsoft-com:office:office"
xmlns:v="urn:schemas-microsoft-com:vml">
ALSO WORKS (o is corrupted)
<v:shape adj="0,,0" coordsize="" id="_x0_0_180_240.0094"
o:spid="_x0000_s1026" o:spt="100" path="" style="blah blah"
xmlns:o="urn:LOOK-MUMMY-I-MADE-IT-UP"
xmlns:v="urn:schemas-microsoft-com:vml">
>> Not that I mind a few extra declarations, but it causes MS Word not to
>> show the picture!
>>
> that sucks - XML should not care about prefixes :-(
So I guess the problem is really with ms word, but can I suggest that
the serializer should follow the prefixes as loaded, rather than
changing the loaded prefix "o" to the new prefix "n1"?
cheers,
andy