How do I block direct hot linking to image files using .htaccess?
Caveats • Your server must allow .htaccess files for this technique to work. • If you do not have a .htaccess file in your root directory, see the related FAQ first. • Do not use this method to redirect image hot links to HTML pages or to servers that are not your own. • Hot linked images can only be replaced by other images, not with HTML pages. • As with any .htaccess rewrite, you may block legitimate traffic, such as users behind proxies or firewalls. Directions • Create a jpeg image called no_hot_link.jpe. Note that the odd file extention (.jpe) is intentional and important. Place this file in your images directory. • Place the following code in the .htaccess file of your root directory.