Skip Menu |

This queue is for tickets about the XML-DOM-Lite CPAN distribution.

Report information
The Basics
Id: 69502
Status: new
Priority: 0/
Queue: XML-DOM-Lite

People
Owner: Nobody in particular
Requestors: anton [...] piatek.co.uk
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.15
Fixed in: (no value)



Subject: XPath matching element values does not work
The following code use XML::DOM::Lite qw(Parser XPath); my $xml_string1 = "<a><b value='foo'/><b value='bar'/></a>"; my $xml = Parser->parse($xml_string1); print XPath->evaluate('count(/a/b[@value="foo"])', $xml); Produces the output 2 As there is only one xml node with "value=foo", this should be returning 1. It appears that selecting an attribute name does work, but filtering on the value of that named attribute does not work. Tested on RHEL6.0 amd64 with perl 5.10.1