private static function guessAbsoluteURL () {
        $scheme = 'http';
        $host = 'localhost';

        if (isset($_SERVER['REQUEST_SCHEME'])) {
            $scheme = $_SERVER['REQUEST_SCHEME'];
        }

        if (isset($_SERVER['HTTP_HOST'])) {
            $host = $_SERVER['HTTP_HOST'];
        }

        return $scheme . '://' . $host . '/';
    }