Bug with headers() + flush()

Discussion about the open-source Phalanger [?] project.

Bug with headers() + flush()

Postby kripper » September 14th, 2017, 8:41 pm

flush() is resetting the HTTP headers()

Sample code:

Code: Select all
<?php
header('Content-Transfer-Encoding: binary');
header('Content-Type: application/vnd.ms-excel');
header('Content-Disposition: attachment; filename=test.xls');
header('Pragma: no-cache');
header('Expires: 0');

echo "Content\n";

flush();

die('ok');


Expected result: headers should be sent.

Actual result: no headers are sent when calling flush().
kripper
 
Posts: 44
Joined: February 19th, 2012, 1:02 am

Re: Bug with headers() + flush()

Postby kripper » October 27th, 2017, 8:50 pm

Please confirm this is a bug in Phalanger.
kripper
 
Posts: 44
Joined: February 19th, 2012, 1:02 am


Return to Phalanger project

Who is online

Users browsing this forum: No registered users and 12 guests

cron

User Control Panel

Login

Who is online

In total there are 12 users online :: 0 registered, 0 hidden and 12 guests (based on users active over the past 5 minutes)
Most users ever online was 256 on March 28th, 2024, 9:42 am

Users browsing this forum: No registered users and 12 guests