Re: Tutorial/Example of Insert/Select PDF Postgres DB ?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



ben wilko wrote:
Hi Guys

I am looking for an examples on how to insert a PDF file into Postgres DB and also selecting it so that someone can download it from a page.

You would be much better off storing the path to the file (or just the filename) in the database, leaving the file itself on the filesystem and password protecting the downloads folder with a .htaccess file or something.

You could then have something like download.php?file=filename.txt and go from there (it would use fpassthru to just spit the file out to the browser etc)..

--
Postgresql & php tutorials
http://www.designmagick.com/


[Index of Archives]     [Postgresql General]     [Postgresql Admin]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Yosemite Backpacking]     [Postgresql Jobs]

  Powered by Linux