Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Feb 2003
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Pop Up Window link

    I understand how to create a pop up window using PopUp(PopUpUrl) but how can I activate the script via a link?

    I need to know how to reference the popup window with a URL ...

    HELP PLEASE!

    Here is the pop up script I am using

    <html>
    <head>
    <title>PopUpScript</title>
    <script>
    function PopUp(PopUpUrl){
    var ScreenWidth=window.screen.width;
    var ScreenHeight=window.screen.height;
    var movefromedge=0;
    placementx=movefromedge;
    placementy=movefromedge;
    WinPop=window.open(PopUpUrl,"","width=500,height=400,toolbar=0,location=0,directories=0,status=0,scr ollbars=0,menubar=0,resizable=1,left="+placementx+",top="+placementy+",screenX="+placementx+",screen Y="+placementy+",");
    }
    </script>
    </head>
    <body>
    <input type="button" name="popbutton" value="Open PopUp" onclick="PopUp('http://********/trainingmodules/basicelectricity/ElectricalTerms.htm')">
    </body>
    </html>

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Location
    Montreal, Canada
    Posts
    644
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You mean this?

    Code:
    <a href="#" onclick="PopUp('http://********/trainingmodules/basicelectricity/ElectricalTerms.htm');">
    
    OR
    
    <a href="javascript: PopUp('http://********/trainingmodules/basicelectricity/ElectricalTerms.htm');">
    Note: There should be no space in the word javascript, the board automatically puts it in.

  • #3
    New to the CF scene
    Join Date
    Feb 2003
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I am using an online training application, which I create modules using Macromedia Director. I am trying to get the shockwave file (.dcr) to open in a window... I embedded it in its own page... the dcr file is but 500x400... and I want the page to open to the same size ... The URL will be called through an app online... the app asks for a URL to link to the page... when I do this, a new page opens up in the wrong size... I figured out how to get the page to open correctly via a button, but I need the page to open correctly on its own, with out the script being in the button. It can only be referenced by a URL...

    How do you use the script you posted Goose??? How do I embed this script in a URL reference. http://??????


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •