Connecting Tech Pros Worldwide Forums | Help | Site Map

window.open problem

Grouchy.Oldgit@googlemail.com
Guest
 
Posts: n/a
#1: Jun 27 '08
Have been successfully using the following to open a pop-up for some
time

function msg(url) {

window.open(url,'msg','scrollbars=yes,menubar=yes, width=750,height=400,resizable=yes,toolbar=yes,loc ation=yes,status=yes')
}

Works fine on IE6 & Firefox, but IE7 opens a new tab obscuring the
calling page. How can IE7 be made to open a new window?

PA Bear [MS MVP]
Guest
 
Posts: n/a
#2: Jun 27 '08

re: window.open problem


IE Tools | Internet Options | General | Tabs | Settings | When a pop-up is
encountered...

Lots more in IE Help! <wink>
--
~Robear Dyer (PA Bear)
MS MVP-IE, Mail, Security, Windows Desktop Experience - since 2002
AumHa VSOP & Admin http://aumha.net
DTS-L http://dts-l.net/


Grouchy.Oldgit@googlemail.com wrote:
Quote:
Have been successfully using the following to open a pop-up for some
time
>
function msg(url) {
>
window.open(url,'msg','scrollbars=yes,menubar=yes, width=750,height=400,resizable=yes,toolbar=yes,loc ation=yes,status=yes')
}
>
Works fine on IE6 & Firefox, but IE7 opens a new tab obscuring the
calling page. How can IE7 be made to open a new window?
Jeremy J Starcher
Guest
 
Posts: n/a
#3: Jun 27 '08

re: window.open problem


On Wed, 25 Jun 2008 10:45:48 -0700, Grouchy.Oldgit wrote:
Quote:
window.open
(url,'msg','scrollbars=yes,menubar=yes,width=750,h eight=400,resizable=yes,toolbar=yes,location=yes,s tatus=yes')
Quote:
}
window.open is NOT required to open a new window. In most modern user
agents, the end use may choose to open window a new window, open a new
tab or ignore the request entirely.
Grouchy.Oldgit@googlemail.com
Guest
 
Posts: n/a
#4: Jun 27 '08

re: window.open problem


Many thanks for prompt reply.

Unfortunately it seems that IE7 by default opens the link in a tab
rather than a pop-up! As most users probably never get past the
defaults, is there any way in javascript to force a link to open in a
pop-up?

On Jun 25, 10:52*am, "PA Bear [MS MVP]" <PABear...@gmail.comwrote:
Quote:
IE Tools | Internet Options | General | Tabs | Settings | When a pop-up is
encountered...
>
Lots more in IE Help! <wink>
--
~Robear Dyer (PA Bear)
MS MVP-IE, Mail, Security, Windows Desktop Experience - since 2002
AumHa VSOP & Adminhttp://aumha.net
DTS-Lhttp://dts-l.net/
>
>
>
Grouchy.Old...@googlemail.com wrote:
Quote:
Have been successfully using the following to open a pop-up for some
time
>
Quote:
function msg(url) {
>
Quote:
window.open(url,'msg','scrollbars=yes,menubar=yes, width=750,height=400,resi*zable=yes,toolbar=yes,lo cation=yes,status=yes')
}
>
Quote:
Works fine on IE6 & Firefox, but IE7 opens a new tab obscuring the
calling page. How can IE7 be made to open a new window?- Hide quoted text -
>
- Show quoted text -
rob^_^
Guest
 
Posts: n/a
#5: Jun 27 '08

re: window.open problem


Hi,

var
nwin=window.open(url,'msg','scrollbars=yes,menubar =no,width=750,height=400,resi*zable=yes,toolbar=no ,location=yes,status=yes');
nwin.focus();
void(0);

Regards.

<Grouchy.Oldgit@googlemail.comwrote in message
news:342e2eeb-962d-486d-b707-15114f9a5c27@j1g2000prb.googlegroups.com...
Quote:
Many thanks for prompt reply.
>
Unfortunately it seems that IE7 by default opens the link in a tab
rather than a pop-up! As most users probably never get past the
defaults, is there any way in javascript to force a link to open in a
pop-up?
>
On Jun 25, 10:52 am, "PA Bear [MS MVP]" <PABear...@gmail.comwrote:
Quote:
>IE Tools | Internet Options | General | Tabs | Settings | When a pop-up
>is
>encountered...
>>
>Lots more in IE Help! <wink>
>--
>~Robear Dyer (PA Bear)
>MS MVP-IE, Mail, Security, Windows Desktop Experience - since 2002
>AumHa VSOP & Adminhttp://aumha.net
>DTS-Lhttp://dts-l.net/
>>
>>
>>
>Grouchy.Old...@googlemail.com wrote:
Quote:
Have been successfully using the following to open a pop-up for some
time
>>
Quote:
function msg(url) {
>>
Quote:
window.open(url,'msg','scrollbars=yes,menubar=yes, width=750,height=400,resi*zable=yes,toolbar=yes,lo cation=yes,status=yes')
}
>>
Quote:
Works fine on IE6 & Firefox, but IE7 opens a new tab obscuring the
calling page. How can IE7 be made to open a new window?- Hide quoted
text -
>>
>- Show quoted text -
>
Richard Cornford
Guest
 
Posts: n/a
#6: Jun 27 '08

re: window.open problem


"rob^_^" <iecustomizer@hotmail.comwrote:
<snip>
Quote:
var nwin=window.open(url,'msg','scrollbars=yes,menubar =no,width=750,
height=400,resi*zable=yes,toolbar=no,location=yes, status=yes');
nwin.focus();
void(0);
<snip>

So which part of that overrides the user's settings and forces IE 7 to
open a new window instead of opening a new tab to show the url?

And what is the - void(0); - statement supposed to do? Pure mystical
incantation or is there some reason for its being there?
Quote:
<Grouchy.Oldgit@googlemail.comwrote:
<snip>
Quote:
Quote:
>... , is there any way in javascript to force a link to open in a
>pop-up?
It is often said that people who top-post don't bother reading what they
are replying to.

Richard.

Closed Thread


Similar JavaScript / Ajax / DHTML bytes