View Full Version : Popup's again

01-04-2004, 11:59 AM
Hy Guys,

The dreaded popup's again. The two pbit od code be low do work. When the first page is loaded it will produce a popup, BUT, it also produces the popup to say that something is trying to close the parent window.

First Page:

<SCRIPT LANGUAGE="JavaScript"><!--
myHandle = window.open('mypage.htm','main','resizable=no,width=400,height=400');
if (!myHandle.opener)
myHandle.opener = self;

Second Page:

<SCRIPT LANGUAGE="JavaScript"><!--

<a href="javascript:window.close()">Close</a>

My question is: Is there any way that the yes button on the parent popup must be clicked to dismiss the window before any other pages can be loaded into the popup window????????


The Dingbat. :confused: :)

01-04-2004, 12:04 PM
Any window not created by you will present that message when you try to close it ...

01-04-2004, 12:22 PM
Thanks MHTML I appreciate that. What I am asking, is there any way to force the user to click on yes before going into the popup?


01-06-2004, 10:07 AM
There's a hack for it but you can't rely on it in the future. And it is advisable to only use it in a controlled environment like the intranet. It's a no-no in the internet.