View Full Version : double link

01-23-2005, 11:39 PM
Hello Could Some one help me with a jscript im making a downloads page and i need a jscrpit that shows a link and when the link is clicked it will direct them to the url of my download and a then loads a new page that says somthing like thanks for downloading so it would like load the download link first that would bring up thge what do you want to do open save or cancil and then it would take them to another page

GB Joe
01-25-2005, 01:13 PM
This might not be a complete answer, but it may be an angle worth trying:

The link in the body:

<a href="one_page.htm" onclick="open_win('popup_page.htm')"><img src="link.gif" name="s3" id="s3"></a>
...and in the head:

function open_win(pagename)
window.open(pagename,"new_page","toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=yes, copyhistory=yes, width=400, height=400")
I got this stuff from the W3Schools website - you could try these links for a breakdown of what all the bits do:

I added the "pagename" variable so I could reuse the code to open different windows, and surprised myself when it actually worked...

02-02-2005, 05:07 AM
ok so that would open 2 windows with one link because i have a download page that i need it to start the download and then redirect the user to a different page or would it open the download link and then the other page???

02-02-2005, 05:21 AM
never mind i got it to work thankyou :cool: :rolleyes: ;) :thumbsup: :thumbsup: :thumbsup:
the only problem is how would i close the blank window that stays popuped up after the download popupsup :confused:

GB Joe
02-02-2005, 09:14 AM
I'll bet someone here smarter than me could tell you how to do this - but personally I'd just live with it! ;)