Generating Popup Windows that Opens Again When They Are Closed


How to generate popup windows that opens again when they are closed?



If you want to generate a popup window that opens again right after you close it, you can use the "closed" attribute of the window object to call the open function repeatedly. See the following JavaScript code outline:

<a href="/javascript:pWindowSetTimeoutTest();">Click...
*  Popup Blocker Test - P_WINDOW_REOPEN
*  - Popup Windows Open Again If They Are Closed
*  A single popup window that will open again if you close
*  it. JavaScript codes used to check the closed status.
*  Version of 2007.01.01
*  Download at
*  Copyright (C) 2007 All rights reserved.
function pWindowReopenStart() {
   fyicenterTimer = window.setInterval(pWindowReopen,1000);
function pWindowReopenStop() {
function pWindowReopen() {
   if (typeof fyicenterWin == 'undefined' || fyicenterWin...
      fyicenterWin ='popup_blocker_test_popu...
         '', 'toolbar=no,scrollbars=no,resizeable=no,widt...

You can also visit Popup Blocker Test - P_WINDOW_REOPEN page to get the complete source code and to see how it works.

2007-01-17, 7598👍, 0💬