Re: CGI scripts / Location header

Brian Behlendorf (
Thu, 12 Oct 1995 00:31:50 -0700 (PDT)

On Wed, 11 Oct 1995, Daniel DuBois wrote:
> Scenario: User requests a URL that points to an existant CGI script. CGI
> script returns a "Location: localfile.html" header, indicating a
> 'server-side' redirect, and this file doesn't exist.

Let me use different terminology. C = client, S = server

C: GET /script.cgi

S: 302 Moved Temporarily
Location: host://server/other-file.html

C: GET /other-file.html

S: 404 Not Found

Whether this is done as two separate connections or one using keep-alive
doesn't really matter, I don't think.

BTW, any reason why Location *has* to be an absolute URL and not a
relative one? That's always been a burden - Netscape and the Microsoft
Explorer handle relative paths alright.

> Is it proper to send a 404 Not Found message?

I think so. The user agent interface should clearly show it was the
request for the second resource, and not the first, which caused the


--=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-- http://www.[hyperreal,organic].com/