#23184 [Opn->Csd]: (null)-value in front of header-location-request
| From: | info at speedpartner dot de | Date: | Wed, 16 Apr 2003 07:44:07 +0000 |
| Subject: | #23184 [Opn->Csd]: (null)-value in front of header-location-request | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-37740@lists.php.net to get a copy of this message | ||
ID: 23184
User updated by: info at speedpartner dot de
Reported By: info at speedpartner dot de
-Status: Open
+Status: Closed
Bug Type: Output Control
Operating System: Linux
PHP Version: 4.3.1
New Comment:
Problem resolved - thanks for your help!
The crucial point was the rfc2616-setting. Although I was for some
reason not able to set its setting via ini_get (why?) I had a look in
the php.ini - and there it was set to 1. Disabling this setting
(because we're running Apache - and "0" is okay in this case) helped.
Don't know how the "1" came into the settings - but now it works.
Thank you!
Previous Comments:
------------------------------------------------------------------------
[2003-04-16 02:10:38] info at speedpartner dot de
The precompiled Win32-binaries work perfect. But when compiling the
latest source for Linux the problem remains. We're using kernel 2.4.20
with Gcc 3.2. Maybe that's of some help? Already tried to track down
the error - but it's not that easy. Where could the string "(null)"
instead of "Status: 302" as the first line of output come from?
Is there maybe any string-object freed but used again later? Then maybe
this is a problem because of Gcc 3.2? But that's just speculation ...
------------------------------------------------------------------------
[2003-04-15 21:27:42] iliaa@php.net
Please try using this CVS snapshot:
http://snaps.php.net/php4-STABLE-latest.tar.gz
For Windows:
http://snaps.php.net/win32/php4-win32-STABLE-latest.zip
If the problem persists, check if you have 'cgi.rfc2616_headers' ini
setting enabled. Via: <?php var_dump(ini_get("cgi.rfc2616_headers"));
?>
------------------------------------------------------------------------
[2003-04-13 04:11:27] info at speedpartner dot de
Using php4.3.1-cgi I with this script:
<?
Header("Location: abcdef.php");
?>
and running it with this:
php x.php
results in:
(null)
Content-type: text/html
Location: abcdef.php
This null-value in front is only present if I'm using a
header-redirect. All setCookie or something works fine and without the
null-value.
Problem is that this null badly confuses apache's mod_proxy because it
interprets the content-type and location as part of the body of the
page and not as real header-values.
Does anybody know where this null comes from? Is it easy to fix
somewhere in the source? Need urgent reply!
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=23184&edit=1