title: Jquery validate csv file
body: <p>i try validate csv file when user upload file with extension/format CSV</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
  $(document).ready(function() {
      $('#form1').validate({
          rules: { csv: { required: true, accept: "csv"  }},
          messages: { csv: "File must be CSV" }
      }); 
  });
  &lt;/script&gt;
  
  &lt;form action="product_import.php?action=import" method="POST" name="form1" id="form1" enctype="multipart/form-data"&gt;
  &lt;input name="csv" type="file" id="csv" /&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>But the problem is when i upload file with extension csv this error message will show up <code>File must be CSV</code>  , i dont know why this script can't accept even i set to <code>accept: "csv"</code> .</p>
  
  <p>My csv file name is <code>product.csv</code></p>