title: Don't allow certain File types while upload
body: <p>I am implementing file upload functionality in this way</p>
  
  <pre><code>&lt;html&gt;
  &lt;head&gt;
  &lt;title&gt;File Uploading Form&lt;/title&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;h3&gt;File Upload:&lt;/h3&gt;
  Select a file to upload: &lt;br /&gt;
  &lt;form action="UploadServlet" method="post"
                          enctype="multipart/form-data"&gt;
  &lt;input type="file" name="file" size="50" /&gt;
  &lt;br /&gt;
  &lt;input type="submit" value="Upload File" /&gt;
  &lt;/form&gt;
  &lt;/body&gt;
  </code></pre>
  
  <p></p>
  
  <p>Now I want to restrict the user with some file types means when browse window will open he will be able to select all the files 
  except <code>.bin</code> &amp; <code>.dat</code>.</p>
  
  <p>Means user will not be able to see that files with type .bin and <code>.bat</code> others he can see it and can go upload them.</p>
  
  <p>I am familiar with <code>accept</code> attribute but, but it's not useful in my case because user should be able to select any file type except these two.</p>
  
  <p>So how can achieve this without validation ?</p>
  
  <pre><code>I want to provide such a functionality that when user clicks on browse button and open a browse window to select a file , he should be able to see only files without .bin or .dat extension
  </code></pre>
  
  <p>Is there any way to do this?</p>
  
  <p>Thanks,</p>