OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   RE: DOM (level 1): moving elements from one document to another

[ Lists Home | Date Index | Thread Index ]
  • From: David Valera <dvalera@pcl-hage.nl>
  • To: 'Julian Reschke' <julian.reschke@gmx.de>, 'XML-Dev' <xml-dev@lists.xml.org>
  • Date: Wed, 11 Oct 2000 15:10:15 +0200

> Hi,
>
> appendChild() doesn't let me add a child if it's
> ownerDocument is different
> from the one where it should be added. What is the easiest
> way to get around
> this (besides manually creating new nodes in the new Document)?

If i understand corerectly, you should be using clonenode and then
appendchild, otherwise you have the problem of two different documents
pointing to the same node...you dont want that...

first clone, then append.

David





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS