471,886 Members | 1,131 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,886 software developers and data experts.

window.open - restore on the screen a minimized window

Hi All,

I use a simple function on a web site, based on this function:

function goVisitSite(Site)
{
NewWindow1 = window.open(Site,
"viewwin",
"toolbar=0,menubar=0,width=900,height=280,top=0,le ft=0,scrollbars=1,resizable=yes");
}

On the main page I have a link which opens a new window with some details.
If I minimize that window, next time I click on a link to open it again, the
content of the page changes, but the window remains minimized in the
taskbar. Is there a way of restoring the window to the screen once I call
the above function?

Regards,
Nicolae
Jul 23 '05 #1
5 16627
"Nicolae Fieraru" <no****@please.com> wrote in message
news:42******@duster.adelaide.on.net...
Hi All,

I use a simple function on a web site, based on this function:

function goVisitSite(Site)
{
NewWindow1 = window.open(Site,
"viewwin",

"toolbar=0,menubar=0,width=900,height=280,top=0,le ft=0,scrollbars=1,resizable=yes");
}

On the main page I have a link which opens a new window with some
details. If I minimize that window, next time I click on a link to
open it again, the content of the page changes, but the window remains
minimized in the taskbar. Is there a way of restoring the window to
the screen once I call the above function?

Regards,
Nicolae


NewWindow1 = window.open(...);
if (NewWindow1)
{
NewWindow1.focus();
}

Although on some versions of Internet Explorer, this will not "Restore"
the window, but rather will flash the taskbar icon.

Other platforms, operating systems and Web browsers, it may do anything
from your desired behaviour to nothing at all.

--
Grant Wagner <gw*****@agricoreunited.com>
comp.lang.javascript FAQ - http://jibbering.com/faq
Jul 23 '05 #2
Maybe - not sure - in the popup put the following in the body tag:
onLoad="this.focus()"

Jul 23 '05 #3
Thank you very much, frizzle, this did the trick for IE6 and for Netscape
7.02

Best regards,
Nicolae
"frizzle" <ph********@hotmail.com> wrote in message
news:11*********************@o13g2000cwo.googlegro ups.com...
Maybe - not sure - in the popup put the following in the body tag:
onLoad="this.focus()"

Jul 23 '05 #4

"Grant Wagner" <gw*****@agricoreunited.com> wrote in message
news:G_***************@news2.mts.net...
"Nicolae Fieraru" <no****@please.com> wrote in message
news:42******@duster.adelaide.on.net...
Hi All,

I use a simple function on a web site, based on this function:

function goVisitSite(Site)
{
NewWindow1 = window.open(Site,
"viewwin",

"toolbar=0,menubar=0,width=900,height=280,top=0,le ft=0,scrollbars=1,resizable=yes");
}

Hi Grant,

Thank you very much for your advice. I didn't test it, because I would have
had to implement the method on more pages, while the solution Frizzle
offered is more convenient for me.

Best regards,
Nicolae
Jul 23 '05 #5
Glad to help ;)

Jul 23 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Archi | last post: by
6 posts views Thread by Les | last post: by
1 post views Thread by Ben Smeets | last post: by
3 posts views Thread by Bernd Liebermann | last post: by
40 posts views Thread by Brian Jorgenson | last post: by
3 posts views Thread by Steve Covert | last post: by
5 posts views Thread by ray well | last post: by
reply views Thread by YellowAndGreen | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.