[vox-tech] Apache, IE, error 404
nbs
vox-tech@lists.lugod.org
Thu, 27 Jun 2002 09:29:51 -0700
On Thu, Jun 27, 2002 at 07:22:28AM -0700, Rod Roark wrote:
> >From Apache's default httpd.conf:
>
> # Customizable error response (Apache style)
> # these come in three flavors
> #
> # 1) plain text
> #ErrorDocument 500 "The server made a boo boo.
> # n.b. the (") marks it as text, it does not get output
> #
> # 2) local redirects
> #ErrorDocument 404 /missing.html
> # to redirect to local URL /missing.html
> #ErrorDocument 404 /cgi-bin/missing_handler.pl
> # N.B.: You can redirect to a script or a document using server-side-includes.
> #
> # 3) external redirects
> #ErrorDocument 402 http://some.other_server.com/subscription_info.html
> # N.B.: Many of the environment variables associated with the original
> # request will *not* be available to such a script.
>
> Looks like #2 is what you are mostly wanting.
Maybe I'm missing something, but I don't think that will do it.
In fact, that's what I already have. Using a non-IE browser, go to,
for example:
http://www.lugod.org/projects/installfests.shtml
and, perhaps, compare it to:
http://www.lugod.org/FooBar/
So I've already got 404 errors doing magical PHP stuff. My issue is,
they are (rightly) being transmitted as "404" responses.
IE notices this, ignores any of the actual HTML content provided by
the webserver (e.g., in the first page up there, the note saying
"You're probably looking for the installfest page: _link_"), and just
plops its crap onto the screen.
I want Apache to say "Ok, this is a 404... BUT... the requester is using
Internet Explorer, so I'll still show them the 404 error page Bill so
tirelessly created, BUT I'll just say it's an "okeydokey" response, not
a 404."
I think someone's suggestion to rewrite headers using PHP might do the
trick for me. If so, I'll post my solution.
Now to track down a Windows box with IE to test with ;)
-bill!