httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From (Sean Conner)
Subject Re: [users@httpd] Strange problem with Options +Indexes
Date Sun, 21 Aug 2005 21:21:31 GMT
It was thus said that the Great Stuart Gall once stated:
> Hello,
> As I understand it <Location something>
> and <Directory something>
> are equivalent except Location refers from the Document root

  Not quite.  <Location> refers to the URL, *not* the directory.  

  For example:

  Actually, go there.  You'll notice that there's *only* a "robots.txt" file
and nothing else.  Yet, go to:

  And you'll get the Biblical story of the flood.  What's going on here? 
Here's the relevent configuration from my server:

  DocumentRoot  /http/spc/sites/
  CustomLog     /http/spc/logs/ combined

  <Directory /http/spc/sites/>
    Options             All
    AllowOverride       All

  <Location /kj/>
    LitbookDir          /http/spc/sites/
    LitbookTranslation  /http/spc/sites/
    LitbookTLD          /kj/
    LitbookTitle        "The Electric King James"
    SetHandler          litbook-handler

  The directory is "/http/spc/sites/" under which,
there's not much there.  *But* the location "/kj" is controlled by a custom
written module that handles the requests. 

> So I have apache 2.0.50 installed on Mandrake
> In one of my virtual hosts I have
>          <Location />
>                  Allow from all
>          </Location>
>          <Location /ppm/storyboard>
>                  Options +Indexes
>                  Allow from all				**
>          </Location>
> When I go to this location with a web browser I see the directory index 
> but with no files UNLESS
> I also include
>          <Directory /document root>
>                  Allow from all
>          </Directory>
> I do not see any files listed.
> Why do I need the double Allow from all ??

  My guess is that you could remove the "Allow" from the <Location>
directive, but keep it for the <Directory> and it will still work. 
<Location> refers to URL space, *not* the directory space.

  -spc (Who wrote the above module for a "proof-of-concept" for an idea
	I had)

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message