ID: 33225
User updated by: phpbugs at thequod dot de
Reported By: phpbugs at thequod dot de
Status: Bogus
Bug Type: Documentation problem
Operating System: *
PHP Version: 5.0.4
New Comment:
In the documentation (at least the german one) it says
that header( 'HTTP/..' ) and header( 'Status: ..' ) do the
same.
Previous Comments:
------------------------------------------------------------------------
[2005-06-06 16:40:57] [EMAIL PROTECTED]
You can set HTTP response code by header("HTTP/ ") and that's what is
documented. "The HTTP status header line will always be the first sent
to the client" is pointing to this header("HTTP/ "), not
header("Status: ").
------------------------------------------------------------------------
[2005-06-06 00:02:21] [EMAIL PROTECTED]
If Apache behaves like that (and CGI), it's not a bug.
Do NOT send multiple status headers if you wish it to work as you
expect.
------------------------------------------------------------------------
[2005-06-05 16:59:14] [EMAIL PROTECTED]
Could you please check the last comment please?
And then return the bug to us if needed.
Thanks,
Nuno
------------------------------------------------------------------------
[2005-06-05 13:45:31] phpbugs at thequod dot de
Sniper, please use a FastCGI-compiled PHP-CGI binary and
don't inspect the Apache output.
If you would have been running php-fastcgi on your Apache2
server you would've gotten a "Internal server error",
because fastcgi dies on multiple Status headers.
It's not only a documentation problem, but causes Internal
Server errors with Apache and fastcgi, because fastcgi is
very strict about the "There has to be exact one status
code in the cgi response".
------------------------------------------------------------------------
[2005-06-03 23:18:04] [EMAIL PROTECTED]
Here's what I get with Apache2 and your script:
HTTP/1.1 302 Found
Date: Fri, 03 Jun 2005 21:15:54 GMT
Server: Apache/2.0.52 (Fedora)
X-Powered-By: PHP/5.1.0-dev
Status: 301
Location: http://www.example.org
Connection: close
Content-Type: text/html; charset=ISO-8859-1
IMO, this is not a bug in either SAPI. Just documentation issue.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/33225
--
Edit this bug report at http://bugs.php.net/?id=33225&edit=1