title: How to avoid fputcsv double quote enclosure
body: <p>I am trying to replace empty field with <code>\N</code> in my csv. To do that I am reading the existing csv and after doing some check. I am writing csv row to temp file but this temp file add double quote around the string.</p>
  
  <p>I am using <code>fputcsv()</code> for this purpose. Is there any way to escape these double quotes?</p>
  
  <pre><code>$ebayorderfile = 'ebay.csv';
  $fh = fopen($ebayorderfile, 'r');
  $headings = fgetcsv($fh, 0, ',');
  $num = count($headings);
  
  $tempfile = tempnam("/orders","tmp");
  $output = fopen($tempfile,'w');
  fputcsv($output,$headings);
  
      while (($row = fgetcsv($fh, 0, ',')) !== FALSE) {   
      $row++;
      $lineString=array();
          for ($c=0; $c &lt; $num; $c++) {
              if(strlen($row[$c])&lt;1){             
                  $row[$c] = "\N";
              }                   
              array_push($lineString,$row[$c]);           
          }
          fputcsv($output,$lineString);   
      }
  
  fclose($fh);
  fclose($output);
  unlink($ebayorderfile);
  rename($tempfile,$ebayorderfile);
  </code></pre>