title: Read CSV in PHP And replace values
body: <p>I have a CSV file which is delivered via FTP to a folder on my web server, </p>
  
  <p><a href="https://i.stack.imgur.com/O316O.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/O316O.png" alt="CSV ORDER FILE - Before"></a></p>
  
  <p>What I need to do is  read the file, and when the order number changes (column 1) alter the Is_Continuation value of the previous row to "N" using PHP, I've got as far as reading the file into an array but cannot get right in my mind the logic of how this is done.</p>
  
  <p>I need to set this a a cron job hence PHP.</p>
  
  <p>Abslolutely any info / advice would be gratefully received.</p>
  
  <p>Thanks</p>
  
  <p><a href="https://i.stack.imgur.com/yI6cN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/yI6cN.png" alt="CSV ORDER FILE - After"></a></p>