httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Zac Stevens <>
Subject Re: [users@httpd] Equivalent of IIS custom 404
Date Tue, 24 Jun 2003 15:13:09 GMT
Hi Aidan,

On Tue, Jun 24, 2003 at 03:43:32PM +0100, Aidan Whitehall wrote:
> It appears as though Apache was reports the information correctly --
> i.e. that there was no query string in the original request, nor in the
> redirection.
> However, I'd have thought some other cgi variable would contain the
> value "casestudies", perhaps cgi.http_referer. Unfortunately, it doesn't
> seem to -- if you dump the entire cgi associative array to the page, the
> string "casestudies" doesn't appear anywhere.

And indeed it should!  When using the ErrorDocument system, a number of
special varibles are set to provide details of the failed request.  You're
probably looking for REDIRECT_URL, but see here for details:

However, while this is a perfectly reasonable way of solving the problem it
probably isn't the best - it's certainly not the most efficient, which may
be a concern if you're expecting this feature to get a workout.

If you are worried about performance and would like to investigate some
other options, two spring to mind immediately.  First of all, mod_rewrite
allows you to define a "RewriteMap" which can make use of an external
program.  Unfortunately, this requires a program which can be run from the
commandline - so your CF redirect system might not work.

The other way would more closely emulate the behaviour you are used to on
IIS, but will require a bit more configuration.  This makes use of the
"path_info" feature, so take a look at this to get an idea about how useful
it might be for you:



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