#1
  1. No Profile Picture
    Homie16
    Guest
    Devshed Newbie (0 - 499 posts)
    Hello i donęt know how to do a automatic
    opening popup can some of you tell me how to do?
  2. #2
  3. No Profile Picture
    Spookster
    Guest
    Devshed Newbie (0 - 499 posts)
    You didn't specify if you wanted it to popup when the user opens your page or when they leave the page. I wrote this script so that it will open a popup window when you enter the page and when you leave the page. Dpending on what you want, you can modify it.

    <HTML>
    <HEAD>
    <TITLE>Opening a Popup Window</TITLE>
    <SCRIPT LANGUAGE=JAVASCRIPT TYPE="TEXT/JAVASCRIPT">
    <!-- Hide script from old browsers

    function popup(){

    popupwindow = window.open("somewhere.html","","toolbar=no,location=no,scrollbars=no,resizable=no,width=400,height= 200,left=500,top=200")

    }
    // End hiding script from old browsers -->
    </SCRIPT>
    </HEAD>
    <BODY onLoad="popup()" onunLoad="popup()">
    <a href="javascriptopup()">Open window</a>
    <br>
    <a href="javascriptopupwindow.close()">Close window</a>
    </BODY>
    </HTML>

    I also put links to show you how to open and close the window from a link.

    Spookster

Similar Threads

  1. How to focus a popup window from another asp page?
    By srivalli9 in forum ASP Programming
    Replies: 0
    Last Post: December 30th, 2003, 08:44 AM
  2. Replies: 1
    Last Post: May 7th, 2003, 03:49 PM
  3. Need help with swapping 2 images in popup win
    By Heinz in forum HTML Programming
    Replies: 4
    Last Post: December 1st, 2002, 08:49 PM
  4. How to go from PopUp window to Main Screen
    By Robert Trost in forum HTML Programming
    Replies: 5
    Last Post: October 28th, 2001, 04:07 PM
  5. How to go from PopUp page to Main Page
    By Robert Trost in forum PHP Development
    Replies: 10
    Last Post: October 28th, 2001, 03:17 PM

IMN logo majestic logo threadwatch logo seochat tools logo