title: HTML5 video (mp4 and ogv) problems in Safari and Firefox - but Chrome is all good
body: <p>I have the following code:</p>
  
  <pre><code>&lt;video width="640" height="360" controls id="video-player" poster="/movies/poster.png"&gt;
   &lt;source src="/movies/640x360.m4v" type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"'&gt;
   &lt;source src="/movies/640x360.ogv" type='video/ogg; codecs="theora, vorbis"'&gt; 
  &lt;/video&gt;
  </code></pre>
  
  <ul>
  <li>I'm using Rails (Mongrel in development and Mongrel+Apache in production).</li>
  <li>Chrome (Mac and Win) can play either file (tested by one then the other source tags) whether locally or from my production servers.</li>
  <li>Safari (Mac and Win) can play the mp4 file fine locally but <em>not</em> from production.</li>
  <li>Firefox 3.6 won't play the video in either OS. I just get a grey cross in the middle of the video player area.</li>
  <li>I've made sure that both Mongrel and Apache in each case have the right MIME types set.</li>
  <li>From Chrome's results I know there is nothing inherently wrong with my video files or the way the files are being asked for or delivered.</li>
  </ul>
  
  <p>For Firefox I looked at <a href="https://developer.mozilla.org/En/Using_audio_and_video_in_Firefox" rel="noreferrer">https://developer.mozilla.org/En/Using_audio_and_video_in_Firefox</a> where it refers to an 'error' event and an 'error' attribute. It seems the 'error' event is thrown pretty well straightaway and at that time there is no error attribute. Does anyone know how to diagnose the problem? </p>