Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

.htaccess File Options -Indexes on Subdirectories

I have the following .htaccess line, simple no indexes on root.

Options -Indexes 

What do we add so it propagates to any sub directory instead of having to create one file for each? One .htaccess on root only.

like image 722
Codex73 Avatar asked Nov 20 '09 01:11

Codex73


1 Answers

The correct answer is

Options -Indexes 

You must have been thinking of

AllowOverride All 

https://httpd.apache.org/docs/2.2/howto/htaccess.html

.htaccess files (or "distributed configuration files") provide a way to make configuration changes on a per-directory basis. A file, containing one or more configuration directives, is placed in a particular document directory, and the directives apply to that directory, and all subdirectories thereof.

like image 98
oasisfleeting Avatar answered Oct 02 '22 04:10

oasisfleeting