0

I Tried Using this:

Options -Indexes

Which works for the Folder but if you write the specific image name like this

www.example.com/images/pictures.jpg

You're Still able to view the image, Is there anyway disable that to?

I also tried using this which does the same thing

IndexIgnore *
Shiv Chand
  • 43
  • 1
  • 6

1 Answers1

0

Hope this help

RewriteEngine on 
RewriteCond %{HTTP_REFERER} !^http://(www\.)?example.com[NC] 
RewriteCond %{HTTP_REFERER} !^http://(www\.)?example.com.*$ [NC] 
RewriteRule \.(gif|jpg)$ - [F]
Dan
  • 294
  • 2
  • 8
  • Original answer is here ;) http://stackoverflow.com/questions/10236717/htaccess-how-to-prevent-a-file-from-direct-url-access – Akaryatrh Jan 14 '14 at 06:20