Fullscreen Mode

G

Guest

Is there a way to detect if the browser is in full screen mode? I see
several posts about how to set fullscreen mode and how it cant be done, but
nothing about how to detect it.
 
J

John Timney \(ASP.NET MVP\)

I would look at detecting what the screen size max is, and then check the
actual available width and height of the browser window to see if they
match.

You'll need a couple of bits of javascript - something like this for the
browser size

For netscape: probably
window.innerWidth;
window.innerHeight;

For IE - probably
window.document.body.clientWidth;
window.document.body.clientHeight;

and a bit of script to get the actualk screen width
if (document.layers || document.all) {
w = screen.availWidth;
h = screen.availHeight;
}Not tried any of these though, you'll have to wing it and see how it goes.
You may need to compensate anywhere for scrollbar widths.-- Regards
John Timney
ASP.NET MVP
Microsoft Regional Director
 
G

Guest

That was my original approach. Unfortunately that method does not
distinguish between full screen mode(F11) and maximized. There are several
pages in the application that display more data than makes good sense, and I
want to be able to tell the user that he should hit F11 for the best
presentation of data. Preferably as a modal.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,901
Latest member
Noble71S45

Latest Threads

Top