ID: 29683 Updated by: [EMAIL PROTECTED] Reported By: ca533512 at tiscali dot cz Status: Open Bug Type: Unknown/Other Function Operating System: Win2k SP4 PHP Version: 5.0.1 New Comment:
This is also reproducible with Apache 1.3.x SAPI. It happens because sapi_module.header_handler (particularly sapi_apache_header_handler() with Apache 1.3.x) returns 0 instead of SAPI_HEADER_ADD and headers just don't get to SG(sapi_headers). Previous Comments: ------------------------------------------------------------------------ [2004-08-23 19:59:52] ca533512 at tiscali dot cz Apache 2.0.50 -- php: `original` for win32 from php.net ------------------------------------------------------------------------ [2004-08-23 18:59:21] [EMAIL PROTECTED] What SAPI are you using? ------------------------------------------------------------------------ [2004-08-14 23:58:00] ca533512 at tiscali dot cz Description: ------------ If I try code from PHP docs of headers_list() function, browser print only empty array. or this function is not available on win OS ? Reproduce code: --------------- /* setcookie() will add a response header on its own */ setcookie('foo', 'bar'); /* Define a custom response header This will be ignored by most clients */ header("X-Sample-Test: foo"); /* Specify plain text content in our response */ header('Content-type: text/plain'); /* What headers are going to be sent? */ var_dump(headers_list()); Expected result: ---------------- array(4) { [0]=> string(29) "X-Powered-By: PHP/5.0.0" // ... 5.0.1 [1]=> string(19) "Set-Cookie: foo=bar" [2]=> string(18) "X-Sample-Test: foo" [3]=> string(24) "Content-type: text/plain" } Actual result: -------------- array(0) { } ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=29683&edit=1