Re: [xml] multiple XPath evaluations on the same document
- From: "Martin (gzlist)" <gzlist googlemail com>
- To: IRENE SIPIKA <piotreks optonline net>
- Cc: xml gnome org
- Subject: Re: [xml] multiple XPath evaluations on the same document
- Date: Thu, 15 Oct 2009 20:23:46 +0100
On 15/10/2009, IRENE SIPIKA <piotreks optonline net> wrote:
Or is there a way for me to use the current 'element' node as the root
for the next xpath query?
Set the 'node' member of the xmlXpathContext to the new context node:
<http://xmlsoft.org/html/libxml-xpath.html#xmlXPathContext>
Or with the python bindings, use the setContextNode method on the
xpathContext object.
You can also compile the xpath expression and use xmlXPathCompiledEval
if you're using it more than once.
Martin
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]