title: Video.js - loadedmetadata event never fires
body: <p>I am having trouble with videojs: when attaching an eventlistener to the "loadedmetadata" event, the callback function is never executed.</p>
  
  <p>The best explanation I found seems to be that some events may fire before Video.js binds the event listeners: <a href="https://stackoverflow.com/questions/16195331/video-js-loadeddata-event-never-fires">Video.js - loadeddata event never fires</a>.</p>
  
  <p>Unfortunately, the solution proposed in this post does not seem to work for me.</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
  &lt;title&gt;test&lt;/title&gt;
  &lt;link href="http://vjs.zencdn.net/4.12/video-js.css" rel="stylesheet"&gt;
  &lt;script src="http://vjs.zencdn.net/4.12/video.js"&gt;&lt;/script&gt;
  &lt;script src="http://code.jquery.com/jquery-2.0.3.min.js"&gt;&lt;/script&gt;
      &lt;script type="text/javascript"&gt;
          function init() {
              var video = document.getElementById('myVideo');
              video.addEventListener("loadedmetadata", function () {
                  alert("test");
              });
          }
          window.addEventListener("load", init);
      &lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
      &lt;video id='myVideo' class="video-js vjs-default-skin" controls data-setup='{}'&gt;
          &lt;source id='mp4' src="http://goo.gl/fAHXgj" type='video/mp4'&gt;
          &lt;source id='webm' src="http://goo.gl/03LOHW" type='video/webm'&gt;
      &lt;/video&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>When I launch it from Visual Studio (2013), the code above produces an alert pop up only in IE(11); it does not work with Firefox nor Chrome.</p>
  
  <p>When I publish it on my website it never works.
  What am I missing? Thank you for reading!</p>