...

View Full Version : Pop Up Window link



Hotspur
02-27-2003, 03:31 AM
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,scrollbars=0,menubar=0,resizable=1, left="+placementx+",top="+placementy+",screenX="+placementx+",screenY="+placementy+",");
}
</script>
</head>
<body>
<input type="button" name="popbutton" value="Open PopUp" onclick="PopUp('http://********/trainingmodules/basicelectricity/ElectricalTerms.htm')">
</body>
</html>

x_goose_x
02-27-2003, 04:53 AM
You mean this?



<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.

Hotspur
02-27-2003, 05:12 AM
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://??????



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum