You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Spartanicus <sp...@ntlworld.ie> on 2006/10/24 09:12:09 UTC
[users@httpd] "Options Indexes" in specified directories only
The web document dir structure on my local dev machine is something like
this:
Document root
|- site one
|- site two
|- site three
|- test
I want "Options Indexes" for the "Document root" and "test" folder, not
for the other folders and without having to specify a config to disable
Indexes in "site one, site two, etc." so that I don't have to worry
about Indexes being enabled by default if I add a "site four".
What is the best way to do this?
I thought about using a regex to target subdirs of my document root to
specify "Options -Indexes", but since Directory containers using a regex
are evaluated last afaics this doesn't allow me to enable Indexes for
"test".
--
Spartanicus
(email whitelist in use, non list-server mail will not be seen)
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] "Options Indexes" in specified directories only
Posted by Vincent Bray <no...@gmail.com>.
On 10/24/06, Spartanicus <sp...@ntlworld.ie> wrote:
> The web document dir structure on my local dev machine is something like
> this:
>
> Document root
> |- site one
> |- site two
> |- site three
> |- test
>
> I want "Options Indexes" for the "Document root" and "test" folder, not
> for the other folders and without having to specify a config to disable
> Indexes in "site one, site two, etc." so that I don't have to worry
> about Indexes being enabled by default if I add a "site four".
>
> What is the best way to do this?
I haven't tried it but does this help?
<Directory /var/www>
Options +Indexes
# ...
</Directory>
<DirectoryMatch /var/www/.+>
Options -Indexes
</DirectoryMatch>
--
noodl
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org