Cake\Http\ResponseEmitter::emitHeaders PHP Метод

emitHeaders() защищенный Метод

Loops through each header, emitting each; if the header value is an array with multiple values, ensures that each is sent in such a way as to create aggregate headers (instead of replace the previous).
protected emitHeaders ( Psr\Http\Message\ResponseInterface $response ) : void
$response Psr\Http\Message\ResponseInterface The response to emit
Результат void
    protected function emitHeaders(ResponseInterface $response)
    {
        foreach ($response->getHeaders() as $name => $values) {
            if (strtolower($name) === 'set-cookie') {
                $this->emitCookies($values);
                continue;
            }
            $first = true;
            foreach ($values as $value) {
                header(sprintf('%s: %s', $name, $value), $first);
                $first = false;
            }
        }
    }