Thanks! Now I'm having a little difficulty understanding how this works.
I have one file that has the following link:
<td><a href=\"download.php?path=../ftp/$path&name=$name\" target=\"_blank\">$name</a></font></b></td>
From what I have read the purpose of download.php is to contain the header information to download the file. This is the only code that I have in download.php:
<?php
$file = $_GET['file'];
$name = $_GET['name'];
header("Content-Type: application/octet-stream");
header("Content-Disposition: attachment; filename=$name");
?>
When I click on the original link above a window pops up with the correct filename asking me if I want to open or save the file, but when I save it to a disk or try opening it, I do not get the file that is on the server. It is simply a blank file or I get an error from the program that is trying to open the file.
What I don't understand is how does download.php know which file to open? Am I taking the right approach to this?
Any feedback would be great. Thanks!