Juan Ramon Jiminez Thomas Jefferson #### use warnings; use strict; use Data::Dumper; use XML::DOM::Lite qw( Parser XPath ); my $doc = Parser->parseFile( '/rshome/jaw2/xml/practice.xml' ); my $result1 = XPath->evaluate( 'quotelist/quotation[@id="q5"/@style', $doc ); print Dumper $result1; my $result2 = XPath->evaluate( '/quotelist/quotation[id="q5"]/source/text()', $doc ); print Dumper $result2;