mirror of https://github.com/flightphp/core
See: http://php.net/manual/en/function.header.php 2nd option, $replace, should be false if sending multiple headers with the same name. The difference can be observed by editing index.php (the example index page) so that before `echo 'hello'` is a line: `flight::response()->cache(false);` and editing Response.php so that before `exit($this->body)` is a line: `var_dump(headers_list());` Before change: `array (size=3)` `0 => string 'Expires: Mon, 26 Jul 1997 05:00:00 GMT' (length=38)` `1 => string 'Cache-Control: max-age=0' (length=24)` `2 => string 'Pragma: no-cache' (length=16)` After: `array (size=5)` `0 => string 'Expires: Mon, 26 Jul 1997 05:00:00 GMT' (length=38)` `1 => string 'Cache-Control: no-store, no-cache, must-revalidate' (length=50)` `2 => string 'Cache-Control: post-check=0, pre-check=0' (length=40)` `3 => string 'Cache-Control: max-age=0' (length=24)` `4 => string 'Pragma: no-cache' (length=16)`pull/27/head
parent
293a1e88ed
commit
69e5dab546
Loading…
Reference in new issue