src/Modernizr.php
public static function getData($key = self::KEY, $cookieExtra = '')
    {
        if (!empty(self::$data)) {
            return self::$data;
        }

        $key .= $cookieExtra;

        if (PHP_SESSION_ACTIVE === session_status() && isset($_SESSION[$key])) {
            self::$data = $_SESSION[$key];

            return self::$data;
        }

        if (isset($_COOKIE) && isset($_COOKIE[$key])) {
            self::$data = self::ang($_COOKIE[$key]);

            if (isset($_SESSION)) {
                $_SESSION[$key] = self::$data;
            }

            return self::$data;
        }

        return null;
    }
public static function getData($key = self::KEY, $cookieExtra = '')
    {
        if (!empty(self::$data)) {
            return self::$data;
        }

        $key .= $cookieExtra;

        if (PHP_SESSION_ACTIVE === session_status() && isset($_SESSION[$key])) {
            self::$data = $_SESSION[$key];

            return self::$data;
        }

        if (isset($_COOKIE) && isset($_COOKIE[$key])) {
            self::$data = self::ang($_COOKIE[$key]);

            if (isset($_SESSION)) {
                $_SESSION[$key] = self::$data;
            }

            return self::$data;
        }

        return null;
    }
public static function getData ( $ key = self :: KEY , $ cookieExtra = '' ) { if ( ! empty ( self :: $ data ) ) { return self :: $ data ; } $ key .= $ cookieExtra ; if ( PHP_SESSION_ACTIVE === session_status ( ) && isset ( $ _SESSION [ $ key ] ) ) { self :: $ data = $ _SESSION [ $ key ] ; return self :: $ data ; } if ( isset ( $ _COOKIE ) && isset ( $ _COOKIE [ $ key ] ) ) { self :: $ data = self :: ang ( $ _COOKIE [ $ key ] ) ; if ( isset ( $ _SESSION ) ) { $ _SESSION [ $ key ] = self :: $ data ; } return self :: $ data ; } return null ; }
returns the data

@param string $key
@param string $cookieExtra

@return array|null
returns the data