PDA

View Full Version : Calling a POP Window Java Script


hamsterpants
01-23-2003, 12:18 PM
Hi All,

I have a java script for a pop window which I have saved as popup.js. I would like to know how I call this script from a link, if that makes sence.

So for example, I have a page with a link, but instead of opening a normal window I want to call the java script file popup.js. also my origional javascript which would normally go in the head has the URL of one page, but obviously this is now going to be determined by the specific link on the page??

beetle
01-23-2003, 03:43 PM
Let's see the contents of popup.js please.

hamsterpants
01-23-2003, 04:43 PM
here you go,

<script>

//Popup Window Script


function openpopup(){
var popurl="thankyou.htm"
winpops=window.open(popurl,"","width=400,height=338,scrollbars,resizable,")
}

</script>

I know that it isn't right because it shouldn't have the url populated as this is going to a variable.