public static function set($cacheloc, $cachekey, $cacheval, $expiresec=false)
    {
        $cacheloc = "cache_" . $cacheloc;
        if ( $cacheval === null || $cacheval === false ) {
            unset($_SESSION[$cacheloc]);
            return;
        }
        if ( $expiresec !== false ) $expiresec = time() + $expiresec;
        $_SESSION[$cacheloc] = array($cachekey, $cacheval, $expiresec);
    }