nofel — 2010-05-17T01:50:49-04:00 — #1
i m crearting a pop with some parameters like locationbar,statusbar=no and its height and width 1280*800. but originally i have given its hight to be 699 to pixel a viewpoint. however i need help with someone who has a less resolution. can i put some if condition. checking if the resolution isn't at 1280 * 800 and if so than the popup should have scroll. is there anymore smater way to handle this? as of now if someone has a less Res. everything get clipped off
nofel — 2010-05-17T04:48:24-04:00 — #2
well i m totally new to JS. for now what i m using is
having that said. those are bits and pieces i gathered from net to come up with what i want. adding to this your code. how will it be? i know i m being a nerd. but would appreciate your help
nofel — 2010-05-17T02:56:28-04:00 — #3
yes i saw that, but given my scanerio i.e if a person is using less Resoultion than 1280 * 800. the scrollbar=yes whereas as of current they are no (leaving a person with with less resoultion not see the page beyond the viewpoint)
felgall — 2010-05-17T02:25:35-04:00 — #4
You can use screen.width and screen.height to get the actual screen resolution but that doesn't take into account any fixed toolbars displayed on the screen.
You can't turn off the locationbar or status bar in modern browsers so the actual space you will have available in the window may be less than you expect.
paul_wilkins — 2010-05-17T04:37:29-04:00 — #5
The following gives you an idea of how to do it.
var useScrollbar = (screen.height < 800) ? 'yes' : 'no';
window.open(..., ..., 'scrollbar='+useScrollbar,...');