[xml] Reparenting nodes across documents?



I'm using manipulation functions like xmlAddChild and xmlAddNextSibiling in my _javascript_ binding library (http://github.com/polotek/libxmljs). ÂI whenever I use these I have a function that checks whether the incoming new node is already a child of a different document and if so it does a node copy and destroys the old node. ÂI've now been told that this isn't necessary because functions like xmlAddChild already do this check and will do the document transfer for me. ÂIs this correct? ÂWhat other things should I take into account whenÂtransferringÂnodes across documents?

:Marco

--
Marco Rogers
marco rogers gmail com

Life is ten percent what happens to you and ninety percent how you respond to it.
- Lou Holtz


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]