title: Handling files from two file inputs
body: <p>I have the following <code>HTML</code> code:</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;table&gt;
    &lt;tr&gt;
      &lt;td&gt;Your photo file&lt;/td&gt;
      &lt;td &gt;&lt;input id="EmpSelfPhoto" type="file" /&gt;&lt;/td&gt;
      &lt;td style='color:red'&gt;Not requiered&lt;/td&gt;
      &lt;/tr&gt;
    
     &lt;tr&gt;
      &lt;td&gt;Your CV file&lt;/td&gt;
      &lt;td&gt;&lt;input id="EmpCV" type="file" /&gt;&lt;/td&gt;
       &lt;td style='color:red'&gt;Requiered&lt;/td&gt;
      &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;/td&gt;
      &lt;td&gt;&lt;input id="PostFile" type="button" value="Upload .." /&gt;&lt;/td&gt;
      &lt;td&gt;&lt;/td&gt;
      &lt;/tr&gt;
    &lt;/table&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>And I'm using <code>Jquery ajax -generic handler</code> to upload the posted files.
  The problem is <code>context.Request.Files.Count</code> will validate for all inputs and I have to loop throw all input using <code>HttpFileCollection</code>.
  <hr />
  <strong>How can I validate each file input separately in server side?</strong> For example <em>I would like to check if file input 1 has file, and check if file input 2 is a valid picture.</em>    </p>