title: Filtering CSV using PHP
body: <p>Hi I have a CSV file that needs filtering, from A-C, D-F and so on     </p>
  
  <pre><code>    Aaron, Male, aaron@website.com
      Arianne, Female, arianne@something.com
      Bea, Female, bea@hello.com
      Carlos, Male, carlos@website.com
      Drake, Male, drake@website.com
      Delilah, Female, del@hello.com
      Erica, Female, erika@webisite.com
      Flint, Male, flint@something.com
  </code></pre>
  
  <p>Im not good at PHP and I tried to fix it by doing  this code below. </p>
  
  <pre><code>&lt;?php
  $file  = fopen('LoggedInUsers.csv', 'r');
  
  $first = array('Aaron');
  $last = array('Carlos');
  
  
  
  while (($line = fgetcsv($file)) !== FALSE) {  
      list($name, $log, $department) = $line;
  
      $firstt = array('Aaron');
      if ($first &lt; 0) {
      }
      $last = array ('Carlos');
      if ($last &lt; 0) {
  }
  ?&gt;
  </code></pre>