Remove apache's DirectoryIndex
Solution 1:
You have a couple of options:
-
Set
DirectoryIndex
to a filename that will never possibly exist.DirectoryIndex lni345hoqvgheruhgreoiuhgeroi30948yt0348
Don't load the
mod_dir
module. This, however, will disable theindex.html
style functionality for the entire server, and is probably not what you want.
Beginning with Apache 2.4 you can set DirectoryIndex disabled
to disable its functionality.
Solution 2:
According to the documentation here, you can use:
DirectoryIndex disabled
to do this, either in your Apache config file, or in .htaccess
.