SileNT
SileNT

Reputation: 623

How to switch the web browser to fullscreen mode with JavaScript?

I'm developing a web application and to improve the user experience I wish to switch the browser in fullscreen mode. Any ideas how to do this (except asking the user to do it himself)?

Upvotes: 2

Views: 3597

Answers (4)

Andreas Köberle
Andreas Köberle

Reputation: 111032

Its possible using the FullScreenApi, which is supported at least in Chrome 27, FF 21, Safari 5.1 and Opera 16. It will be also supported by IE 11. There is also a minor wrapper for API.

Upvotes: 4

NM.
NM.

Reputation: 1929

Javascript.resizeTo(screen.width,screen.height)

Upvotes: 1

spinon
spinon

Reputation: 10857

You can't do full screen but you can just resize the window to the available width and height of the screen.

Upvotes: 0

Digital Human
Digital Human

Reputation: 1637

Its not possible. If you really want it, you have to open a new window:

var win = window.open('html.file', 'Name', 'fullscreen=true');

Upvotes: 0

Related Questions