title: PHP - check whether a imported file is a csv or not
body: <p>Hello there I have a code where I import a csv file to mysql database so far it imports csv it will not import image, video and such but it imports files like SQL and PHP, is there a problem with the code? Any help is appreciated. The code for validating whether its a csv file or not.</p>
  
  <pre><code>$csvMimes = array('text/x-comma-separated-values', 'text/comma-separated-values', 'application/octet-stream', 'application/vnd.ms-excel', 'application/x-csv', 'text/x-csv', 'text/csv', 'application/csv', 'application/excel', 'application/vnd.msexcel', 'text/plain');
  </code></pre>