public function setHeaders(array $headers)
    {
        parent::addHeaders($headers);

        $this->setServerGlobal('HTTP_HOST', (string) $this->getHeader('Host')[0]);
        $this->setServerGlobal('HTTP_ACCEPT', (string) $this->getHeader('Accept')[0]);
        $this->setServerGlobal('HTTP_CONNECTION', (string) $this->getHeader('Connection')[0]);
        $this->setServerGlobal('HTTP_USER_AGENT', (string) $this->getHeader('User-Agent')[0]);
        $this->setServerGlobal('HTTP_ACCEPT_ENCODING', (string) $this->getHeader('Accept-Encoding')[0]);
        $this->setServerGlobal('HTTP_ACCEPT_LANGUAGE', (string) $this->getHeader('Accept-Language')[0]);
        $this->setServerGlobal('HTTP_ACCEPT_CHARSET', (string) $this->getHeader('Accept-Charset')[0]);
        $this->setServerGlobal('HTTP_CACHE_CONTROL', (string) $this->getHeader('Cache-Control')[0]);
        $this->setServerGlobal('HTTP_COOKIE', (string) $this->getHeader('Cookie')[0]);
    }
public function setHeaders(array $headers)
    {
        parent::addHeaders($headers);

        $this->setServerGlobal('HTTP_HOST', (string) $this->getHeader('Host')[0]);
        $this->setServerGlobal('HTTP_ACCEPT', (string) $this->getHeader('Accept')[0]);
        $this->setServerGlobal('HTTP_CONNECTION', (string) $this->getHeader('Connection')[0]);
        $this->setServerGlobal('HTTP_USER_AGENT', (string) $this->getHeader('User-Agent')[0]);
        $this->setServerGlobal('HTTP_ACCEPT_ENCODING', (string) $this->getHeader('Accept-Encoding')[0]);
        $this->setServerGlobal('HTTP_ACCEPT_LANGUAGE', (string) $this->getHeader('Accept-Language')[0]);
        $this->setServerGlobal('HTTP_ACCEPT_CHARSET', (string) $this->getHeader('Accept-Charset')[0]);
        $this->setServerGlobal('HTTP_CACHE_CONTROL', (string) $this->getHeader('Cache-Control')[0]);
        $this->setServerGlobal('HTTP_COOKIE', (string) $this->getHeader('Cookie')[0]);
    }
public function setHeaders ( array $ headers ) { parent :: addHeaders ( $ headers ) ; $ this -> setServerGlobal ( 'HTTP_HOST' , ( string ) $ this -> getHeader ( 'Host' ) [ 0 ] ) ; $ this -> setServerGlobal ( 'HTTP_ACCEPT' , ( string ) $ this -> getHeader ( 'Accept' ) [ 0 ] ) ; $ this -> setServerGlobal ( 'HTTP_CONNECTION' , ( string ) $ this -> getHeader ( 'Connection' ) [ 0 ] ) ; $ this -> setServerGlobal ( 'HTTP_USER_AGENT' , ( string ) $ this -> getHeader ( 'User-Agent' ) [ 0 ] ) ; $ this -> setServerGlobal ( 'HTTP_ACCEPT_ENCODING' , ( string ) $ this -> getHeader ( 'Accept-Encoding' ) [ 0 ] ) ; $ this -> setServerGlobal ( 'HTTP_ACCEPT_LANGUAGE' , ( string ) $ this -> getHeader ( 'Accept-Language' ) [ 0 ] ) ; $ this -> setServerGlobal ( 'HTTP_ACCEPT_CHARSET' , ( string ) $ this -> getHeader ( 'Accept-Charset' ) [ 0 ] ) ; $ this -> setServerGlobal ( 'HTTP_CACHE_CONTROL' , ( string ) $ this -> getHeader ( 'Cache-Control' ) [ 0 ] ) ; $ this -> setServerGlobal ( 'HTTP_COOKIE' , ( string ) $ this -> getHeader ( 'Cookie' ) [ 0 ] ) ; }
Sets the headers.

@param array $headers associative array containing the new HTTP headers
Sets the headers .