public function getHeader($key)
    {
        $key = str_replace('-', '_', strtoupper($key));

        if ($this->hasHeader($key)) {
            return $_SERVER[$key];
        }

        if ($this->hasHeader('HTTP_'.$key)) {
            return $_SERVER['HTTP_'.$key];
        }

        return null;
    }
public function getHeader($key)
    {
        $key = str_replace('-', '_', strtoupper($key));

        if ($this->hasHeader($key)) {
            return $_SERVER[$key];
        }

        if ($this->hasHeader('HTTP_'.$key)) {
            return $_SERVER['HTTP_'.$key];
        }

        return null;
    }
public function getHeader ( $ key ) { $ key = str_replace ( '-' , '_' , strtoupper ( $ key ) ) ; if ( $ this -> hasHeader ( $ key ) ) { return $ _SERVER [ $ key ] ; } if ( $ this -> hasHeader ( 'HTTP_' . $ key ) ) { return $ _SERVER [ 'HTTP_' . $ key ] ; } return null ; }
Get Request header

@param  string $key
@return bool|string
Get Request header