title: How to open programmatically the file dialog box in Firefox
body: <p>I want to open the file dialog box programmatically when the user press a key.
  I have grabbed some solutions in <a href="https://stackoverflow.com/questions/2048026/open-file-dialog-box-in-javascript">thess answers</a> but none of them seems to work with Firefox.</p>
  <p><a href="http://jsfiddle.net/jeum/cebm2shm/21/" rel="nofollow noreferrer"><strong>My fiddle is here</strong></a> : simply press the Spacebar to open the file picker (after 1 click on the 'Result' section)</p>
  <p>As you can see I have tried some functions to simulate click : <code>'eventFire'</code> (or more simply <code>el.click();</code>) works with all browsers except FF, but <code>'simulateClick'</code> <a href="https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Creating_and_triggering_events#Triggering_built-in_events" rel="nofollow noreferrer">wich comes from MDN</a> doesn't work with FF (?)</p>
  <pre><code>  var event = new MouseEvent('click', {
      'view': window,
      'bubbles': true,
      'cancelable': true
    });
    el.dispatchEvent(event);
  </code></pre>
  <p>May be is it due to the fact that <code>el</code> is an input ?</p>
  <p>How can I achieve this in FF ?</p>