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

Re: [xml] Extracting multiple XML fragments of the same type



On Wed, Aug 21, 2002 at 02:26:13PM +0200, Holger Rauch wrote:
> On Tue, 20 Aug 2002, Daniel Veillard wrote:
> 
> > [...]
> >   Basically you shouldn't have to serialize and reparse every fragment,
> > simplest is probably to create each new document using
> >   doc = xmlNewDoc("1.0");
> > and then use 
> >   xmlDocCopyNode(curNode, doc, 1);
> > to generate a new copy of the tree in the new document.
> 
> That's what I tried, but even though curNode correctly points to a
> <Document>, doc only contains the XML declaration after these two steps.
> Did I miss anything?
> 
> Thanks for any help!

  No idea, run it under a debugger, put a breakpoint in xmlDocCopyNode
and see what's happening ! You have the context, I don't, so please report.

Daniel

-- 
Daniel Veillard      | Red Hat Network https://rhn.redhat.com/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/



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