开发者

IE9 is overriding the poster attribute for an HTML5 video with a thumbnail of the video

I want to use a custom开发者_开发知识库 poster image, and while this works and all the good browsers, stupid IE9 displays it for a few milliseconds, and then loads a thumbnail of the video. Is there any attribute or other way to prevent this?


First of all: IE behavior is stupid, but was correct according to the HTML5 specification (not anymore?). If you want to blame someone, you should blame Apple/Quicktime, because, they have requested to be able to drop the poster attribute, if video's metadata is loaded (You can see this behavior in Safari4 with older Quciktime plugin). Now, Chrome and Safari have corrected thier behavior and then they changed spec (Nice move).

Yes you can change this behavior by using a workaround, simply use preload="none" on your video element:

<video preload="none" poster="path/to/poster.jpg" src="path/to/video.mp4"></video>


preload="none" seems to solve the missing poster problem in IE9, however it effectively disables controls in Opera - in that the video progress bar indicator remains at the beginning of the video while it is playing.

Not a huge issue, except that it happens. Would like to know if there is a script to enable preload="none" in IE, and have preload="auto" in all other browsers.


See my solution for the poster issue in IE9:

http://www.artbymikeshaffer.com/vids/finalproject_chetbakerquartet_poster7.html

Some simple CSS and conditional statements did the trick. I'm now of the opinion posters should be placed at the beginning (first frame) and end (last frame) of a video, as if they were album covers. In this way, an image at the beginning and end of the video will give the view SOME visual idea of why they should play the video (just like the reason you buy an album sometimes is because of the cover).

My two cent's worth,

Cheers

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜