0

I have a problem that people can access the "folders" through html here is my link www.frebind.16mb.com/frontend/ I was here for answer PHP: How to hide my application folders in .htaccess But the RedirectMatch 403 ^./sub-folder-name/ does not work in case where /sub-folder-name/ contains profile picture links after it eg: RedirectMatch 403 ^./profile_pictures/ and the profile pictures now won't show even if I use this RedirectMatch 403 ^.*/profile_pictures/ I did put the index.html in that folder but it shows the result as without that index... What am I supposed to do to hide it from public? NOTE: this have to be in public folder cause the hostinger does not support user/admin folders as far as I know *Sorry for any grammar mistakes...

Community
  • 1
  • 1
Steven Tomko
  • 98
  • 11
  • Is your problem that people can see the contents of your folders or that people can see URLs of your folders? In order to host the profile pictures, people need to be able to publicly access them. – Jon Lin Mar 24 '15 at 20:46
  • people can see the contents of the folders... so .php .jpg files etc... – Steven Tomko Mar 25 '15 at 10:25

1 Answers1

0

If you want to prevent people from seeing the contents of your folders, either remove the indexes option:

Options -Indexes

from the htaccess file in your document root. Or add a blank index file to each of your folders, like an index.html file.

Jon Lin
  • 142,182
  • 29
  • 220
  • 220