"window.open" question

A

arajunk

In Firefox this opens a full size window (maximized) . In IE it opens
the partial window requiring user to click restore (upper right) to
maximize. What am I missing ?

var
infoWindow=window.open('usgsMain.html','USGSwindow','status=no,resizable=yes,scrollbars=yes');
 
R

RobG

In Firefox this opens a full size window (maximized) . In IE it opens
the partial window requiring user to click restore (upper right) to
maximize. What am I missing ?

That different browsers have different methods to determine the default
size of pop-ups. They also provide users with different levels of
control over what you can do with pop-ups like removing features,
resizing, raising, lowering, etc.

Some will also force pop-ups to open in a new tab. The best thing to
do is not attempt to open a pop-up at all, just navigate to the page.
That way, users without scripting wont be disadvantaged. If the user
wants the content in a new tab or window, they'll do that themselves.
You might consider placing the content in the existing page.
 
F

Frank van Wensveen

In Firefox this opens a full size window (maximized) . In IE it opens
the partial window requiring user to click restore (upper right) to
maximize. What am I missing ?

The parameters that define the x/y dimensions and offset. When you
leave them out, the browser will substitute its own defaults.
Different browsers, different defaults.

Try:

var
infoWindow=window.open('usgsMain.html','USGSwindow','toolbar=no,location=no,directories=no,status=no,menubar=no,\
scrollbars=no,resizable=yes,copyhistory=no,width=400,height=300,\
screenX=150,screenY=150,top=150,left=150');

and insert the values that work for you.


Regards,
Frank
 
D

dd

In Firefox this opens a full size window (maximized) . In IE it opens
the partial window requiring user to click restore (upper right) to
maximize. What am I missing ?

var
infoWindow=window.open('usgsMain.html','USGSwindow','status=no,resizable=yes,scrollbars=yes');

That's not actually opening a maximized window, even in Firefox.
What's happening is that when Firefox opens new windows, it
chooses the same size as the window that opened it. With IE,
the window opens the same size as the last time IE was closed.

You can verify this by playing around with any website and
right-click on a link and select "open in new window".

With IE, close all your IE's except for one, resize it to an unusual
size, then close it. Now open a new IE, maximize it, visit a site and
then right-click on a link and open in new window. You'll see the
new window as the same unusual size you last clsoed with. Same
trick doesn't work with Firefox, it just inherits the size of the
window it's spawned from.

If the window you want to open is opening content of your own
authoring, then you can make it resize to whatever you want.
You can't "maximize" it, but you can make it as big as possible.
Using the properties screen.width and screen.height you can
use the self.moveTo(x,y) and self.resizeTo(x,y) functions to move
to zero,zero and resize to maximum.
 

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

No members online now.

Forum statistics

Threads
473,981
Messages
2,570,188
Members
46,731
Latest member
MarcyGipso

Latest Threads

Top