问题
HTML5 audio do not work in IE10, but works in Chrome. Any idea?
The HTML used is following,
回答1:
The IE10 on Win8 or RT does not support wav, however, IE10 Mobile does! I attache the screenshots so you can see which formats are supported on both IE10s.
The top one is IE10 (Metro) on Windows 8 RT, and the bottom is IE10 Mobile on WP8 / Lumia 920. (For whatever reasons, the mobile ver is displayed larger here.)
回答2:
IE10 doesn't support wav. You can always use this page to test audio formats on different browsers.
回答3:
Check your server (or local machine) to associate the file types correctly. On a unix system you can add:
AddType video/ogg .ogv
AddType video/mp4 .mp4
AddType video/mp4 .m4v
AddType video/webm .webm
to an .htaccess file. You can serve it from the same directory the video files are hosted in. While most browsers properly interpret the file's MIME types, IE (and some older browsers) do not.
回答4:
Google Chrome, I think looks at both the header of the .mp3 file and then the file length. Rightly or wrongly it defaults to the file length. IE, correctly uses only the file header. If you are using evaluation software then the header file length is often restricted until purchased, even though it shows and plays your complete .mp3 file in the evaluation software.
来源:https://stackoverflow.com/questions/13339291/html5-audio-element-do-not-work-in-ie10-but-works-in-chrome-why