Remove apache's DirectoryIndex

Solution 1:

You have a couple of options:

  1. Set DirectoryIndex to a filename that will never possibly exist.

    DirectoryIndex lni345hoqvgheruhgreoiuhgeroi30948yt0348
    
  2. Don't load the mod_dir module. This, however, will disable the index.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.