title: File type missing in file upload
body: <p>I have a page that will allow me to upload a CSV file.  Using PHP I then take the contents of the CSV file and insert them into a MySQL database.  I've been doing this with no problems for awhile now.  Then today, I tried uploading the file and it didn't work.  The problem is that there appears to be no file type associated with the CSV file.  For example, on a good upload, the debug messages I spit out look like this:</p>
  
  <pre><code>You uploaded a file: buylist_235.csv 
  file type: application/vnd.ms-excel 
  file size: 10456 
  
  File is valid, and was successfully uploaded. Here is some more debugging info:Array (
          [csv] =&gt; Array
              (
                  [name] =&gt; buylist_235.csv
                  [type] =&gt; application/vnd.ms-excel
                  [tmp_name] =&gt; C:\xampp\tmp\php3C1E.tmp
                  [error] =&gt; 0
                  [size] =&gt; 10456
              )
  )
  </code></pre>
  
  <p>However, when I upload the problem file with the debug messages on I noticed the file type and file size is empty.</p>
  
  <pre><code>You uploaded a file: buylist_235_1.csv
  file type: 
  file size: 0
  
  Possible file upload attack!
  Here is some more debugging info:Array
  (
      [csv] =&gt; Array
          (
              [name] =&gt; buylist_235_1.csv
              [type] =&gt; 
              [tmp_name] =&gt; 
              [error] =&gt; 2
              [size] =&gt; 0
          )
  
  )
  </code></pre>
  
  <p>Anyone have any ideas why the file type is empty?  In Windows Explorer, if I hover over either of these files the info balloon over the files say "Type: Microsoft Excel Comma Separated Values File".  But there is something wrong with the second file that causes my PHP to puke and not recognize the file type.</p>