title: XML to CSV conversion issue
body: <p>I really need some help on an issue: I'm converting an XML to CSV using a PHP script, but I only need to get certain fields in the CSV, not all of them. Is there any way to specify which fields I want to import?</p>
  
  <p>This is the XML file structure:</p>
  
  <pre><code>&lt;PRICES&gt;
  &lt;PRICE&gt;
  &lt;WIC&gt;HDE0AAFGRBOX&lt;/WIC&gt;
  &lt;DESCRIPTION&gt;some text here&lt;/DESCRIPTION&gt;
  &lt;STOCK&gt;100&lt;/STOCK&gt;
  &lt;MY_PRICE&gt;219.00&lt;/MY_PRICE&gt;
  &lt;IMAGE&gt;some image here&lt;/image&gt;
  &lt;EAN-CODE&gt;some code here&lt;/EAN-CODE&gt;
  &lt;/PRICE&gt;
  &lt;/PRICES&gt;
  </code></pre>
  
  <p>This is the script I use:</p>
  
  <pre><code>&lt;?
  $filexml='stock.xml';
  if (file_exists($filexml)) {
  $xml = simplexml_load_file($filexml);
  $f = fopen('stock.csv', 'w')
  foreach($xml-&gt;PRICES-&gt;PRICE as $price) {
  fputcsv($f, get_object_vars($price),',','"');
  }
  fclose($f);
  }
  ?&gt;
  </code></pre>
  
  <p>I only need to get WIC, STOCK and MY_PRICE.</p>
  
  <p>Any help will be greatly appreciated.</p>
  
  <p>Thanks in advance!</p>