Behavior of namespace during appendChild

Hi experts,

I have a question regarding appendChild
http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-184E7107

Maybe my question is covered in this FAQ, but the answer is not clear to me.
http://www.w3.org/DOM/faq.html#namespacefixup

1) What should be the result of appending 'child' in
<root><child/></root> to <newparent xmlns="q"/> ?
a) <newparent xmlns="q"/><child/></newparent>
b) <newparent xmlns="q"/><child xmlns=""/></newparent>

2) And what should be the result of appending 'child' in
<root xmlns=""><child/></root> to <newparent xmlns="q"/> ?
a) <newparent xmlns="q"/><child/></newparent>
b) <newparent xmlns="q"/><child xmlns=""/></newparent>

Thanks in advance,
Gerwin Jansen

Received on Monday, 31 October 2011 16:16:52 UTC