Please disregard my question. Everything is working fine. Chalk it up as stupid user error.
Thanks.
From: "Aaron Schubert" <shaggyshubes99 hotmail com>
To: xml gnome org
Subject: [xml] xmlAddChild (and namespace)
Date: Thu, 27 Apr 2006 16:47:32 +0000
MIME-Version: 1.0
X-Originating-IP: [69.145.86.254]
X-Originating-Email: [shaggyshubes99 hotmail com]
X-Sender: shaggyshubes99 hotmail com
Received: from menubar.gnome.org ([209.132.176.177]) by bay0-mc5-f16.bay0.hotmail.com with Microsoft SMTPSVC(6.0.3790.1830); Thu, 27 Apr 2006 09:48:45 -0700
Received: from localhost (unknown [127.0.0.1])by menubar.gnome.org (Postfix) with ESMTPid F16133B1832; Thu, 27 Apr 2006 12:48:12 -0400 (EDT)
Received: from menubar.gnome.org ([127.0.0.1]) by localhost (menubar.gnome.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 17067-10; Thu, 27 Apr 2006 12:48:09 -0400 (EDT)
Received: from menubar.gnome.org (localhost.localdomain [127.0.0.1])by menubar.gnome.org (Postfix) with ESMTPid 015DA3B0F02; Thu, 27 Apr 2006 12:48:07 -0400 (EDT)
Received: from localhost (unknown [127.0.0.1])by menubar.gnome.org (Postfix) with ESMTP id 324793B0398for <xml gnome org>; Thu, 27 Apr 2006 12:48:05 -0400 (EDT)
Received: from menubar.gnome.org ([127.0.0.1])by localhost (menubar.gnome.org [127.0.0.1]) (amavisd-new, port 10024)with ESMTP id 17067-09 for <xml gnome org>;Thu, 27 Apr 2006 12:48:04 -0400 (EDT)
Received: from hotmail.com (bay101-f21.bay101.hotmail.com [64.4.56.31])by menubar.gnome.org (Postfix) with ESMTP id 30A9B3B01B5for <xml gnome org>; Thu, 27 Apr 2006 12:48:04 -0400 (EDT)
Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC;Thu, 27 Apr 2006 09:48:02 -0700
Received: from 64.4.56.200 by by101fd.bay101.hotmail.msn.com with HTTP;Thu, 27 Apr 2006 16:47:32 GMT
Hello, I am trying to add a node and am doing so successfully except that the namespace declarations are lost? The xml from both of these docs has the namespace in question defined. Example follows.
// assume both these are valid and belong to separate xmlDocs
xmlNodePtr content_node
xmlNodePtr body_node
// sc is the xmlDocPtr I want to add the node to
body_node = xmlDocCopyNode(body_node, sc, 1);
xmlAddChild(content_node, body_node->children);
xmlDocDumpMemory(sc,&new_doc,&new_doc_size);
ret_xml = (char *) new_doc;
// The ret_xml has everything there except the namespace declarations from the body_node. So, rather than rn:special_tag I get special_tag. I guess something extra must be done to declare the namespace.
Find just what you're after with the new, more precise MSN Search - try it now!
>_______________________________________________
>xml mailing list, project page http://xmlsoft.org/
>xml gnome org
>http://mail.gnome.org/mailman/listinfo/xml