2

My HTML5 audio player, when running inside of IE9, has trouble playing audio files located on a server running Apache Tomcat. For example, it'll never load the file at this path:

http://www.siascend.com/repository/audios/1017_Q1.mp3

but happily plays the same file located @:

http://hirebrodie.com/demo/audio/1017_Q1.mp3

Either path works fine when the player runs in Chrome or Safari. Why wouldn't it work in Internet Explorer? Is this a known issue with the IE implementation of HTML5 audio?

Dennis
  • 32,200
  • 11
  • 64
  • 79
poorBrodie
  • 23
  • 2

1 Answers1

2

Tomcat by default specifies for a .mp3 extension the MIME type audio/x-mpeg.Changing this default to audio/mpeg solves the issue.In other words IE9 is NOT comfortable with audio/x-mpeg but accepts audio/mpeg as MIME type of a resource for an tag.

Source: http://social.msdn.microsoft.com/Forums/pl-PL/iewebdevelopment/thread/b4f58d95-ac27-4a28-a4ae-86477ddfc74f

Rups
  • 629
  • 1
  • 8
  • 19
  • 1
    Changing the MIME type in the web.xml worked like a charm. Thank you so much! – poorBrodie Dec 24 '12 at 19:55
  • 1
    Would you happen to know what MIME IE9 prefers for .m4a files? – idbehold Dec 24 '12 at 22:46
  • To enable your web server to support the audio formats you need to ensure that the web server such as Apache can serve the appropriate file fomats – if some browsers get media errors, add the following mime types to the ‘.htaccess’ at the root web serving folder: AddType audio/mpeg mp3 AddType audio/mp4 m4a AddType audio/ogg ogg oga – Rups Dec 25 '12 at 05:15
  • For more info: http://crosstown.coolestguyplanettech.com/web-host/43-no-video-with-supported-format-and-mime-type-found – Rups Dec 25 '12 at 05:16