Is there a way to make HTML5 video fullscreen?

2019-01-02 17:53发布

Is there a way to play a video fullscreen using the HTML5 <video> tag?

And if this is not possible, does anybody know if there is a reason for this decision?

20条回答
零度萤火
2楼-- · 2019-01-02 18:23

I think that if we want to have a open way to view videos in our browsers without any closed source plugins (and all the security breaches that comes with the history of the flash plugin...). The tag has to find a way to activate full screen.. We could handle it like flash does: to do fullscreen, it has to be activated by a left click with your mouse and nothing else, I mean it's not possible by ActionScript to launch fullscreen at the loading of a flash by example.

I hope I've been clear enough: After all, I'm only a french IT student, not an english poet :)

See Ya!

查看更多
其实,你不懂
3楼-- · 2019-01-02 18:24

A programmable way to do fullscreen is working now in both Firefox and Chrome (in their latest versions). The good news is that a spec has been draft here:

http://dvcs.w3.org/hg/fullscreen/raw-file/tip/Overview.html

You will still have to deal with vendor prefixes for now but all the implementation details are being tracked in the MDN site:

https://developer.mozilla.org/en/DOM/Using_full-screen_mode

查看更多
登录 后发表回答