How to disallow accessing jpg or png files directly??
bebebunny
Joined: 2013-04-21
Posts: 23
Posted: Mon, 2014-02-03 22:16
I want to disable visitor from accessing direct files like jpg or png? i have edited album permission but only protecting the album, not individual image.
htaccess is what you're after, but it'll have consequences that you may not want. (e.g. search engines wouldn't be able to index those files unless you add several lines of code to allow them special access; social media might not be able to display those little images next to links shared from your site; etc, etc.)
Do an internet search on hotlinking and it'll show you how to format the htaccess.
Posts: 1857
htaccess is what you're after, but it'll have consequences that you may not want. (e.g. search engines wouldn't be able to index those files unless you add several lines of code to allow them special access; social media might not be able to display those little images next to links shared from your site; etc, etc.)
Do an internet search on hotlinking and it'll show you how to format the htaccess.
Posts: 27300
If you have protected the album then you should _NOT_ be able to access the image directly.
FAQ: Are my photos secure? They're right there on my website!
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team