title: Return values of two tags which has same name, in an array
body: <p>My XML:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8" ?&gt;
  &lt;CONFIG&gt;
    &lt;item&gt;
      &lt;phone&gt;1234578&lt;/phone&gt;
      &lt;phone&gt;876543321&lt;/phone&gt;
     &lt;/item&gt;
  &lt;/CONFIG&gt;  
  </code></pre>
  
  <p>I need to get both the numbers in an array with 2 elements.</p>
  
  <p>My Perl code:</p>
  
  <pre><code>my $xmlDoc = XML::LibXML-&gt;new-&gt;parse_file($config_file);
  $Xpath = XML::LibXML::XPathContext-&gt;new($xmlDoc);
  
  my @item = $Xpath-&gt;findnodes('/CONFIG/item');
  my $phone = $item[0]-&gt;findvalue('/CONFIG/item/phone');
  print $phone
  </code></pre>
  
  <p>output:</p>
  
  <pre><code>1234578876543321
  </code></pre>
  
  <p><code>$phone</code> contains a single string with both the numbers concatenated as a single entity</p>
  
  <p>I even tried with returning to array context, it still returns one element with both numbers concatenated</p>
  
  <p>Can you please help me get these two phone numbers separately?</p>