In url localhost/newproject/app/webroot/admin/
all images are directly viewable in form of listings. Images should be accessible in webpage but not directly through folder.
Asked
Active
Viewed 261 times
0
-
here is post related to your question, maybe it will help you. :) http://stackoverflow.com/questions/2679524/block-direct-access-to-a-file-over-http-but-allow-php-script-access just vote up this so we can know if this helps you. :) – r3mmel Oct 16 '14 at 05:35
1 Answers
0
Create a .htaccess file in your directory where you need to prevent directly list of images and put this code :
Options -Indexes

Prakash Saini
- 481
- 3
- 11