UTA Libraries Online


Using JavaScript to Create Pop-up Windows


You can use a Pop-up window code generator, such as the ones at http://javascript.internet.com/generators/popup-window.html to save yourself some typing (and also save yourself from having to memorize how the code goes).

  1. Put the main part of the JavaScript in the HEAD (using the HTML view in FrontPage):

    <SCRIPT LANGUAGE="JavaScript">
    <!-- Begin
    function popUp(URL) {
    day = new Date();
    id = day.getTime();
    eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=500,height=450,left = 450,top = 350');");
    }
    // End -->
    </script>

  1. Put the following script where you want the link to be. This is the link that will open a pop-up window:
  2. And, that's all there is to it!



UTA Libraries Online
Send comments to: libraryweb@uta.edu
Box 19497 - University of Texas at Arlington - Arlington, Texas - 76019 - (817) 272-3000
Last Modified: Thursday, 08-Aug-2002 15:10:12 CDT
Copyright © UTA Libraries