empty index.html files needed?

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Locked
BadPriTT

empty index.html files needed?

Post by BadPriTT »

Is it true there are empty index.html files in cmsms and subdirectories? If so, why is this?

Do I need them or can I safely delete/not upload them?
Nick Smart
Forum Members
Forum Members
Posts: 116
Joined: Mon Jul 28, 2008 4:48 pm

Re: empty index.html files needed?

Post by Nick Smart »

Empty index.html files can be deleted and CMSMS will still work correctly.

However, they are a useful security measure to prevent users who navigate directly to a sub-directory from seeing the content of the sub-directory. Try navigating to a sub-directory with and without the empty index.html present to see the difference.

If you still can't see the sub-directory contents when the index.html has been deleted means that something else is blocking access to the directory listing. This is a good thing, but it is still worth leaving the empty index.html files in place.

Nick
BadPriTT

Re: empty index.html files needed?

Post by BadPriTT »

Thanks Nick.

Does this mean there have to be an empty index.html file in every subdir, even if there is a index.php file?

I can impossibly try every subdir, there are to many!
Nick Smart
Forum Members
Forum Members
Posts: 116
Joined: Mon Jul 28, 2008 4:48 pm

Re: empty index.html files needed?

Post by Nick Smart »

Every sub-directory should have an index.php or index.html file in it.

Alternatively read this - http://wiki.cmsmadesimple.org/index.php ... l_Settings - and look at the example .htaccess files and these lines:

Code: Select all

# Turns off directory browsing
# not absolutely essential, but keeps people from snooping around without 
# needing empty index.html files everywhere
Options -Indexes
One .htaccess file in the root is all you need. I would still leave the empty index.html files alone.

Nick
Last edited by Anonymous on Wed Aug 20, 2008 10:44 am, edited 1 time in total.
BadPriTT

Re: empty index.html files needed?

Post by BadPriTT »

Thanks. I used an empty index.html in every dir now. Hope this works. :)

I will look into the extra options later, it is quite some stuff to dig into right now ;)
Locked

Return to “CMSMS Core”