Page 1 of 1
ftp popup
Posted: Fri Feb 27, 2004 3:14 pm
by Infinity
what i need to do is link to a php page called redirect.php and when this page loads i want to redirect it to my ftp server in a popup or new browser window without having to click a link
thanx
Posted: Fri Feb 27, 2004 3:18 pm
by ol4pr0
a redirect within a redirect wich leeds to the ftp server in a new browser?
my best guess is -> java
the redirecting part you could do with php, the popup -> java
Correct me if i am wrong

Posted: Fri Feb 27, 2004 3:20 pm
by Illusionist
try making a JS function to open a page in a new window, and then in your redirect.php(it doesn't even have to be a php file) you can put
<body onLoad="newWin()"> where newWin() is the name of your JS function taht open a new window.
Posted: Fri Feb 27, 2004 3:21 pm
by Illusionist
Actually, it wouldn't even have to be a different page. you could put that JS function in your main page that has the link to redirect.php, and then on your link just do something like:
<a href="#" onClick="newWin()">FTP</a>
Posted: Fri Feb 27, 2004 6:28 pm
by tim
in case you do not know how to write the function, using the above info it might look something like this:
Code: Select all
<script language=javascript>
function newWin() {
window.open("your ftp site address", "Ftp","width=#,height=#");
}
</script>
you can set your own sizes in place of the #'s.
/ edit, cheers for the correction ill.
Posted: Fri Feb 27, 2004 6:57 pm
by Illusionist
not a new window to redirect.php, but the new window to your FTP site
Posted: Fri Feb 27, 2004 8:25 pm
by Infinity
Code: Select all
<?php<script language=javascript>
function newWin() {
window.open("your ftp site address", "Ftp","width=#,height=#");
}
</script>
?>
Ah yes thats what im looking for
thanx guys
Posted: Fri Feb 27, 2004 8:45 pm
by Illusionist
Suggestion: When posting code other than PHP don't use the PHP tags, use the CODE tags
Posted: Sat Feb 28, 2004 6:33 am
by Infinity
sorry force of habit