One of the things that some of the larger download sites have that smaller "downloads" sites sometimes don't is a way to track how many times a file has been downloaded. Places like Download.com keep records of how often a certain file gets downloaded - that way, they can tell which ones they need to promote more and which ones are doing the promotion themselves. So, how can you get this feature like the "bigs boys" of downloading? This new article from DevArtciles might be just what you're looking for.
The piece starts off showing you a bad way to make the file download (as well as leaving a large security hole in your application), and follows it with their way - using Apache rewrite rules and some fun PHP tricks to get the correct file from your server. They show you how to grab the file, send the correct header type for the information, and then send it off to the remote user's browser in a way that it will name it correctly (no more "download.php" on everything! woo!)
This isn't a bad way to do it but you might look into the security aspects of having a file path on the URL line. You could open up a wide hole of you happen to get a user who might know to replace /foo/bar with /etc/passwd...




