title: Countdown to the end of the HTML5 video
body: <p>Can I make a countdown to the end of the HTML5 video?</p>
  
  <pre><code>&lt;video id="video" width="400" height="225" preload="auto"&gt;
      &lt;source src="video.mp4" type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"' /&gt;
  &lt;/video&gt;
  &lt;div id="countdown"&gt;Video ends after &lt;span&gt;XX&lt;/span&gt; seconds.&lt;/div&gt;
  </code></pre>
  
  <p>I understand that a have to wait for the video load, and then if the video is loaded, need to know the length and run video and coundown.</p>