Re: [xml] Get sub-document from xmlDocPtr





Andrew Hartley wrote:

Having extracted a sub-document with an XPath expression and now have an
xmlXPathObjectPtr is there a simple way to output the sub-document into a
new xmlDocPtr so that this sub-document can then be saved to disk?



It's ok, I have worked it out:

[code]
xmlDocPtr pXmlSubDoc = pXPathObj->nodesetval->nodeTab[0]->doc;
[/code]
-- 
View this message in context: http://www.nabble.com/Get-sub-document-from-xmlDocPtr-tp18504765p18505535.html
Sent from the Gnome - Lib - Xml - General mailing list archive at Nabble.com.




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