title: FileReader onload with result and parameter
body: <p>I can't manage to get both the result of the filereader and some parameters in a onload function. This is my code:</p>
  
  <p>HTML of control:</p>
  
  <pre><code>&lt;input type="file" id="files_input" multiple/&gt;
  </code></pre>
  
  <p>Javascript function:</p>
  
  <pre><code>function openFiles(evt){
      var files = evt.target.files;
      for (var i = 0; i &lt; files.length; i++) {
        var file=files[i];
        reader = new FileReader();
        reader.onload = function(){
            var data = $.csv.toArrays(this.result,{separator:'\t'});
        };
        reader.readAsText(file);
      }
    }
  </code></pre>
  
  <p>Add event:</p>
  
  <pre><code> files_input.addEventListener("change", openFiles, false);
  </code></pre>
  
  <p>I use the <code>filereader.result</code>, in the <code>onload</code> function. If I use a parameter, like file, for this function, I can't not access to the result anymore. For example I'd like to use <code>file.name</code> in the onload function. How to resolve this issue ?</p>