title: Clearing File Upload
body: <p>I have jQuery function to validate the file extension of the uploaded file. If the the file does not belong to a desired file extensions then a validation message will be shown and I will clear the value of <code>File Upload</code> via jQuery as</p>
  
  <pre><code>$('#ctl00_ContentPlaceHolder1_FileUpload').val("")
  </code></pre>
  
  <p>It is working fine in modern browsers but not in IE 8. I also tried</p>
  
  <pre><code>document.getElementById('ctl00_ContentPlaceHolder1_FileUpload').value = ''
  </code></pre>
  
  <p>but not working also. my full code is</p>
  
  <pre><code>if ($.inArray(ext, ['gif', 'png', 'jpg', 'jpeg', 'bmp']) == -1) {
      alert('Image must be .jpg/.jpeg/.gif/.bmp/.png only.');
      $('#ctl00_ContentPlaceHolder1_FileUpload').val("");
      document.getElementById('ctl00_ContentPlaceHolder1_FileUpload').value = '';
      $("#ctl00_ContentPlaceHolder1_FileUpload").focus();
  }
  </code></pre>