I think the best way of protecting your files is by creating them dynamicly. Yes.. this does drive up the server-load but files are safe! No direct downloads, hotlinks..
Just put lets say your images into a htaccess-protected folder.
Make a new php-file in your root that you protect by handing over correct varaibles with the header of the desired file type.
for instance for a jpg you would want:
PHP Code:
header('Last-Modified: '.gmdate('D, d M Y H:i:s', $timestamp).' GMT'); header("Content-type: image/jpeg"); $im = imagecreatefromjpeg("YOURIMAGE"); imagejpeg($im, '', 100); imagedestroy($im);
in that file.. watch out that there is no text in the output! .. for a gif just exchange the content-type header to image/gif
Doing this with animated gifs is a bit more work..
a lot of help are the post on php.net when searching for a function.