[SOLVED] Download help!

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
Joe
Forum Regular
Posts: 939
Joined: Sun Feb 29, 2004 1:26 pm
Location: UK - Glasgow

Download help!

Post by Joe »

I was wondering. Is there any function that allows you to download a file from the server. I have created a small script which shows the files in the /test/ directory and beside each file is a button to download the file. Now, I originally made it like:

Code: Select all

<a href="test/$file">Download</a>
but that just brings me to the page rather than asking the me for a location to save the file.

Any help appreciated!


Joe 8)
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

[devnet]+force +download[/devnet]
User avatar
Joe
Forum Regular
Posts: 939
Joined: Sun Feb 29, 2004 1:26 pm
Location: UK - Glasgow

Post by Joe »

Thanks feyd, that is exactly what I required. Problem solved!
Post Reply