Turn off directory browsing?

Quick one - how do I turn off directory browsing server-wide for all virtual servers?

E.G. when someone goes to www.yourdomain.com/images - it won’t let them browse all the images?

Thanks in advance!

Hey Alex,

This is generally set per-virtual server, rather than server-wide. It’s the “Options Indexes” directive in the Directory section.

You can change it in your Server Template(s) for all future virtual servers. In the System Settings menu click Server Templates, select the "Apache website" section. In the "Directives and settings for new websites" remove the "Indexes" option from the "Options" line.

For existing ones, you can use the Apache module to disable it. Select the domain you want to edit in the dropdown, then open the Services menu, then click the "Document Options" icon. Find the option labeled, "Generate directory indexes" and set it to "No".

Repeat for any domains you want this change on.

Save it and click Apply changes in the upper right corner.

You could also just edit the httpd.conf (or the individual domain configuration files) and find all of the lines that read:

[code:1]Options Indexes IncludesNOEXEC FollowSymLinks[/code:1]

And remove "Indexes".<br><br>Post edited by: Joe, at: 2007/06/29 00:16