Hi Perl Monks, I am trying to grab values from an XML file and store it in an array. The XML has data about books and there are multiple values with the same name. I am able to print these values using the code below however, I am unable to store these in an array. Any help will be much appreciated
foreach my $authors ($doc->findnodes('/result/hits/hit/info')) { my @array = map{$_->textContent} $authors->findnodes('./author +s/author'); print $_->textContent, "\n" for $authors->findnodes('. +/authors/author'); }
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |