title: RegEx for specific extension validation
body: <p>I'm trying to validate upload file extensions on client side (razor) with DataAnnotations, however it looks like no matter what file I'm uploading I always get the "Error Message",</p>
  
  <pre><code> [RegularExpression(@"^.*\.(jpg | JPG | gif | docx | doc | DOC | pdf | PDF)$",
             ErrorMessage = "bla bla")]
          public IFormFile MyImage { get; set; }
  </code></pre>
  
  <p>My code is as follows:</p>
  
  <pre><code> &lt;input name="MyImage" class="input-validation-error" id="MyImage" aria-invalid="true" aria-describedby="MyImage-error" type="file" data-val="true" data-val-regex-pattern="^.*\.(jpg | JPG | gif | docx | doc | DOC | pdf | PDF)$" data-val-regex="bla bla"&gt;
  </code></pre>