download files

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
dourvas
Forum Commoner
Posts: 26
Joined: Fri Dec 05, 2008 7:21 am

download files

Post by dourvas »

hello,
i have an upload script that a user can upload files to a directory. i also have a log file that saves the upoload data.

log file:
December 14, 2008/ 07:18:44pm from=Dourvas-little.txt- uploaded by 127.0.0.1
December 14, 2008/ 07:18:53pm From=Dourvas-z.doc- uploaded by 127.0.0.1

Now i need a download script in order to some other users can direct download all the contents of the upload directory
i want to use some certain data from the logfile

for example in the download page i want this kind of info:

in December 14, 2008/ 07:18:44pm Dourvas uploaded little.txt [download link]

i have some thoughts but i find it very difficult task. do u have any ideas?
User avatar
jaoudestudios
DevNet Resident
Posts: 1483
Joined: Wed Jun 18, 2008 8:32 am
Location: Surrey

Re: download files

Post by jaoudestudios »

To force the download of a file, you need to send the right headers.

This may help...
http://www.forum.jaoudestudios.com/view ... 5d7e599b0f
Post Reply