List Info

Thread: Is there any API for getting the XPATH string for a known node?




Is there any API for getting the XPATH string for a known node?
user name
2006-07-14 06:32:59
I am using the libxml2 library.In my program, I have got a
node pointer
and I want to get the XPATH string for this node.I did not
find the
specific API.May anybody help?

Best regards,
Morris

_______________________________________________
xml mailing list, project page  http://xmlsoft.org/
xmlgnome.org
http://mai
l.gnome.org/mailman/listinfo/xml
Is there any API for getting the XPATH string for a known node?
user name
2006-07-15 11:31:40
On Fri, Jul 14, 2006 at 02:32:59PM +0800, 张凯 wrote:
> I am using the libxml2 library.In my program, I have
got a node pointer
> and I want to get the XPATH string for this node.I did
not find the
> specific API.May anybody help?

  There is xmlGetNodePath() (check the function name it is
from memory)
it is not 100% garanteed to provide a correct XPath path, we
had some
errors reported recently but they were fixed. Try it and
report if you
have troubles (as usual 

Daniel


-- 
Daniel Veillard      | Red Hat http://redhat.com/
veillardredhat.com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ |
Rpmfind RPM search engine http://rpmfind.net/
_______________________________________________
xml mailing list, project page  http://xmlsoft.org/
xmlgnome.org
http://mai
l.gnome.org/mailman/listinfo/xml
[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )