On my site, if you browse to
http://example.com/images/ the contents of the entire directory are shown like so:
How can I make it so that this doesn't happen?
Can I create an
.htaccess file in that directory? Or is there a better way? I really want to block directory listing for the entire site (i.e. every directory on that site).
I figure it's either something that has to be done in Apache or using an global
.htaccess file and placing it in the
public_html folder, perhaps?
I diverted this using an
index.php file, but I still feel that security is an issue here, how can I fix this permanently?