I'm trying to stop people from seeing all the files in a folder. Say if you have the folder http://www.somesite.com/files/ and there isn't a index file then it will show a list of all the files in the folder. I have over 30,000 folders though and can't add a index file for each one. Is there a way to stop that via apache?
Most efficient is to put that in your VirtualHosts section for the domain in your httpd.conf Otherwise just put it in the root .htaccess file and it will be inherited in all subfolders. (And when I say it, I mean the code nick posted "Options -Indexes")
It is usually within a <Directory> directive... something like: . . . <Directory /name/of/directory/to/protect> Options -Indexes </Directory> . . .