httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <dgau...@arctic.org>
Subject Re: [PATCH] EVIL hack
Date Sat, 01 May 1999 16:53:47 GMT


On Tue, 27 Apr 1999, Raymond S Brand wrote:

> This message contains an EVIL hack. It is a patch that can be applied AFTER
> applying my patch to mod_autoindex.
> 
> >From my patch to mod_autoindex:
> > Quirks:
> > 	Some of the environment variables, as displayed by mod_include's #printenv, reflect
> > 	the header or readme file, not the directory. See the following "EVIL hack" message.
> 
> The following patch fixes the problem. It suffers from the following problems:
> 	1) mod_autoindex now requires mod_include.
> 	2) mod_include must be LoadModuled before mod_autoindex
> 	3) There REALLY needs to be a better way to do this so that
> 		independent modules do not become dependent on each
> 		other.

You know, to be honest, I'm thinking that mod_autoindex invoking
mod_include is the wrong way around.

If you were to add this to mod_autoindex:

static const handler_rec autoindex_handlers[] =
{
    {DIR_MAGIC_TYPE, handle_autoindex},
+   {"force-directory-index", handle_autoindex},
    {NULL}
};

And put a config directive such as:

AddHandler force-directory-index .force_index

Then <!--#include virtual="foo.force_index" -->

You should end up being able to invoke mod_autoindex from
mod_include... and solve both of the problems you've posted patches for.

I may have it slightly wrong -- I did produce a patch for this some time
ago, I forget what the reason for it was then.

Dean

Mime
  • Unnamed multipart/mixed (inline, None, 0 bytes)
View raw message