MEDIA_ERR_SRC_NOT_SUPPORTED html5 audio woes

前端 未结 2 886
渐次进展
渐次进展 2021-01-11 12:56

I am working on an html5 audio player and everything is working fine when I server the .ogg file from the same host as the html page. When I put the ogg file in my cdn it fa

2条回答
  •  说谎
    说谎 (楼主)
    2021-01-11 13:30

    The Content-Type=octet/stream header is the problem, although if I'm reading the spec correctly, it shouldn't be. Here's a testcase: http://mozilla.doslash.org/stuff/video-test/video.html

    I filed a bug in Mozilla's bugzilla about this. [edit] the response:

    We don't do any content sniffing to work out what the content is - we rely on the correct mime type being provided. This is why application/octet-stream does not play and way we return "" for canPlayType.

提交回复
热议问题