Re: serving all images through a file

From: Date: Tue, 08 Apr 2003 09:03:57 +0000
Subject: Re: serving all images through a file
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-142822@lists.php.net to get a copy of this message
On Tue, 2003-04-08 at 01:48, Justin French wrote: > I'm quoting and experimenting with some code for a site which includes a 5 > level permission system for the images (no prize for guessing it's an > "adult" related site). Why don't I get projects like this? :( > > Anyway, I'm toying with the idea that all images in a certain directory will > be blocked via a .htaccess file so that they can't be served by Apache. > If you are doing .htaccess, might as well have .htpasswd authentication. Excellent tutorials on .htpasswd and other forms of authentication using PHP can be at Zend ( http://www.zend.com/zend/tut/authentication.php ) > However, the *theory* is that this site will generate a LOT of traffic, and > I'm a little concerned about the big picture... > > Will forcing all images through this image script cause a bottle neck on the > site, or do anything stupid like triple server load? In theory, it would make your site slow to load, which is a bad thing for any website, but especially a no-no for an adult site. One thing I would suggest is hotlink protection on your image dir for the image extensions. Along the same lines, a simple thing you can do it rename your images to some obscure extension .. like zbf. This will deter people from farming your server for images. All you'd have to do is adjust the Add-Type line in Apache so it serves zbf as gif, etc. -- Burhan Khalid phplist[at]meidomus[dot]com

« previous php.general (#142822) next »