final public static function session_regenerate_id($delete_old_session = false)
    {
        if ( !self::$started ) return false;

        if ( $delete_old_session ) self::session_destroy();
        else {
            self::$started = null;
            self::$file = null;
            self::$id = null;
        }

        if ( isset($_COOKIE[session_name()]) ) unset($_COOKIE[session_name()]);
        return self::session_start();
    }
final public static function session_regenerate_id($delete_old_session = false)
    {
        if ( !self::$started ) return false;

        if ( $delete_old_session ) self::session_destroy();
        else {
            self::$started = null;
            self::$file = null;
            self::$id = null;
        }

        if ( isset($_COOKIE[session_name()]) ) unset($_COOKIE[session_name()]);
        return self::session_start();
    }
final public static function session_regenerate_id ( $ delete_old_session = false ) { if ( ! self :: $ started ) return false ; if ( $ delete_old_session ) self :: session_destroy ( ) ; else { self :: $ started = null ; self :: $ file = null ; self :: $ id = null ; } if ( isset ( $ _COOKIE [ session_name ( ) ] ) ) unset ( $ _COOKIE [ session_name ( ) ] ) ; return self :: session_start ( ) ; }
Update the current session id with a newly generated one

@link http://www.php.net/manual/en/function.session-regenerate-id.php

@param  boolean $delete_old_session (optional) Whether to delete the old associated session file or not.
@return boolean
Update the current session id with a newly generated one