Re: [PHP] protecting downloads with php

2002-05-12 Thread Peter H. Lemieux
It can be tricky to write download wrappers that work with all browsers. Some versions of Internet Explorer seem especially troublesome. I've found wrappers like these seem to work fairly well: initialization(); authorization($user,$pw); $info=get_file_info($filepointer); ### SEND HEADERS ###

Re: [PHP] protecting downloads with php

2002-05-11 Thread Miguel Cruz
On Sat, 11 May 2002, Nick Wilson wrote: I've been asked to protect an area containing 'course material' (pdf's etc) and have just thought of a gaping hole in what I've done. I use an class to handle all the auth stuff and each page checks the value of $obj-logged_in :: No problem. but

Re: [PHP] protecting downloads with php

2002-05-11 Thread Nick Wilson
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 * and then Miguel Cruz declared I use an class to handle all the auth stuff and each page checks the value of $obj-logged_in :: No problem. but what if someone links to www.thesite/theProtectedArea/file.tar.gz that file cannot

RE: [PHP] protecting downloads with php

2002-05-11 Thread John Holmes
Subject: Re: [PHP] protecting downloads with php On Sat, 11 May 2002, Nick Wilson wrote: I've been asked to protect an area containing 'course material' (pdf's etc) and have just thought of a gaping hole in what I've done. I use an class to handle all the auth stuff and each page checks

Re: [PHP] protecting downloads with php

2002-05-11 Thread Steve Overall
Nick: As John H. suggested earlier, storing files outside (above) the webroot makes those files inaccessible directly from the user's browser-- a good thing-- in which case the script serves as a gateway to these files-- also a good thing. I have a similar need. Here's one way to do it in two

Re: [PHP] protecting downloads with php

2002-05-11 Thread Steve Overall
[EMAIL PROTECTED] To: PHP-General [EMAIL PROTECTED] Sent: Saturday, May 11, 2002 2:44 AM Subject: Re: [PHP] protecting downloads with php -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 * and then Miguel Cruz declared I use an class to handle all the auth stuff and each page checks

RE: [PHP] protecting downloads with php

2002-05-11 Thread Miguel Cruz
... -Original Message- From: Miguel Cruz [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 11, 2002 2:23 AM To: PHP-General Subject: Re: [PHP] protecting downloads with php download.php: ? if (userIsAuthorized) { header('Content-Type: application/x-gzip

Re: [PHP] protecting downloads with php

2002-05-11 Thread Miguel Cruz
On Sat, 11 May 2002, Nick Wilson wrote: Does anyone know of somewhere that lists content-type's? Apache comes with a file in conf/mime.types that lists a lot of standard ones. miguel -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php