Re: downloading files
| From: | Greg Donald | Date: | Fri, 06 May 2005 04:01:41 +0000 |
| Subject: | Re: downloading files | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-214585@lists.php.net to get a copy of this message | ||
On 5/5/05, Cima <ruel.cima@facinf.uho.edu.cu> wrote:
> i've uploaded some files into my postgresql db, via a php script, and now
> id like to give a user the posibility to download these files via a php
> script. what would be the best way to do this bearing in mind that the files
> are 'integrated' into the db and are referenced by an oid. the table that
> contains the files has the original filename in one column and the oid of
> the file in another column besides other info on the table.
> any sugestion would be highly apreciated!
Send the correct file type header() based on the file name's
extension, then send the data.
--
Greg Donald
Zend Certified Engineer
http://destiney.com/