Re: [PHP-DB] File Downloads

[email protected] (Karl DeSaulniers)
Newsgroups php.db
Message-ID <[email protected]>
On May 28, 2010, at 4:18 PM, Adam Schroeder wrote:

> Hi Karl --
>
> You can store the file contents outside of the web tree and use PHP  
> to "read" the contents.  This allows you to place access control  
> restrictions in the PHP script.
>
> This post talks about doing something similar with images.   
> Obviously, if you have a music track... you'll need to adjust the  
> mime type accordingly.
>
> http://stackoverflow.com/questions/258365/php-link-to-image-file- 
> outside-default-web-directory/258380#258380
>
> Good luck.
>
> Adam
>
>
> -----Original Message-----
> From: Karl DeSaulniers [mailto:[email protected]]
> Sent: Friday, May 28, 2010 1:39 PM
> To: [email protected]
> Subject: [PHP-DB] File Downloads
>
> Hello,
> How can I go about restricting the number of downloads of a file on
> my server?
> For Eg: if I want a music track to only be able to be downloaded by
> 150 people and thats it.. ever,
> how can I go about doing this?
>
> Much obliged,
>
> Karl DeSaulniers
> Design Drumm
> http://designdrumm.com
>
>

Very Nice. Good link.
I think this is the route I may go.
Seems a bit more secure if the php script gains access to the file  
through the .htaccess files set-up.

Thanks Adam.

Karl DeSaulniers
Design Drumm
http://designdrumm.com
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.