W3C home > Mailing lists > Public > www-talk@w3.org > September to October 1995

Re: CGI scripts / Location header

From: M. Hedlund <hedlund@best.com>
Date: Fri, 13 Oct 1995 11:59:55 -0700
Message-Id: <v02120d00aca466835219@[]>
To: Daniel DuBois <ddubois@rafiki.spyglass.com>, www-talk@w3.org
At 9:14 AM 10/11/95, 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.
>Is it proper to send a 404 Not Found message?  The URL is found, but the
>output of the CGI script isn't.  Is it better to send a 500 Internal Error

The CGI script should decide.  If it can't cope with not finding the file,
it will not send a proper response and likely cause a 500 (or an empty
document).  If it can, it should send a 404 with some HTML explaining the
problem.  If you send a 500 from a properly-functioning script, it will
appear as though the script is malfunctioning when it is not.

The script is acting as part of the server, and should react as the server

M. Hedlund <hedlund@best.com>
Received on Friday, 13 October 1995 15:02:03 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:32:58 UTC