title: How to pass a file select event in jquery?
body: <p>Here is a file input element </p>
  
  <pre><code>&lt;input type="file" id="url" name="url[]" multiple /&gt;
  </code></pre>
  
  <p>Now the code that listen's to its on change event </p>
  
  <pre><code>document.getElementById('url').addEventListener('change', handleFileSelect, false);
  </code></pre>
  
  <p>The function</p>
  
  <pre><code>function handleFileSelect(evt) {
      var files = evt.target.files; // FileList object
  }
  </code></pre>
  
  <p>This works perfectly fine ..!!</p>
  
  <p>But this does not</p>
  
  <pre><code>&lt;input type="file" id="url" name="url[]" multiple onchange="handleFileSelect()" /&gt;
  </code></pre>
  
  <p>It throws an error "TypeError: evt is undefined"</p>
  
  <p>how to get the event passed for the second one as well?</p>