jasny / sso

Simple Single Sign-On for PHP

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

getallheaders in nginx service not found

dongm2ez opened this issue · comments

getalheaders() in nginx service not found

maye be you can use this code:

if (!function_exists('getallheaders')) {
    function getallheaders() {
        foreach ($_SERVER as $name => $value) {
            if (substr($name, 0, 5) == 'HTTP_') {
                $headers[str_replace(' ', '-', ucwords(strtolower(str_replace('_', ' ', substr($name, 5)))))] = $value;
            }
        }
        return $headers;
    }
}

Duplicate of #79