Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is possible automatic fullscreen with html5?

I'm based on Using the Fullscreen API in web browsers (http://hacks.mozilla.org/2012/01/using-the-fullscreen-api-in-web-browsers ) for fullscreen , but only works with a click event or with console firebug, not with submit event or mouseover or similar for made automatic. Is possible automatic fullscreen with html5 without click event or similar ?

Edit: I understand the security and accessibility reasons if not possible, but in some environments this can be hopeful.

like image 760
richie-torres Avatar asked Jul 19 '12 19:07

richie-torres


2 Answers

No, it's not possible - for security reasons accessing full screen requires the user's "permission", and so is tied to browser input events.

like image 191
Alnitak Avatar answered Oct 05 '22 07:10

Alnitak


No, that is not possible. The requestFullScreen() must be triggered by a direct user action (like a click) for security considerations. It's just the same as with popups.

Read https://wiki.mozilla.org/Security/Reviews/Firefox10/CodeEditor/FullScreenAPI and maybe https://wiki.mozilla.org/Gecko:FullScreenAPI for reference.

like image 30
Bergi Avatar answered Oct 05 '22 07:10

Bergi