public function getToken()
    {
        if (isset($_SESSION[$this->session_name])) {
            return $_SESSION[$this->session_name];
        } else {
            $token = uniqid($this->randomString());
            $_SESSION[$this->session_name] = $token;
            return $token;
        }
    }
public function getToken()
    {
        if (isset($_SESSION[$this->session_name])) {
            return $_SESSION[$this->session_name];
        } else {
            $token = uniqid($this->randomString());
            $_SESSION[$this->session_name] = $token;
            return $token;
        }
    }
public function getToken ( ) { if ( isset ( $ _SESSION [ $ this -> session_name ] ) ) { return $ _SESSION [ $ this -> session_name ] ; } else { $ token = uniqid ( $ this -> randomString ( ) ) ; $ _SESSION [ $ this -> session_name ] = $ token ; return $ token ; } }
Getting a token

@return string Return result

@version v2.0.0
@author Dmitrii Shcherbakov <atomcms@ya.ru>
Getting a token