Ec (2); Code: & nbsp; $ my_session_id $ _ COOKIE [session_name ()]; Save the sessionid of the current employee; session_start ();....... some operations, such as verifying whether the current user has the permission to operate on session updates {here we can cyclically operate on the sessionsession_write_close (); & nbsp; se script ec (2 ); script
Code:
$ My_session_id = $ _ COOKIE [session_name ()]; // Save the session id of the current employee;
Session_start ();
Some operations, such as verifying whether the current user has the permission to perform session update
{// Here you can cyclically operate sessions of multiple other users
Session_write_close ();
Session_id ($ _ refresh_user_sessoin_id); // $ _ refresh_user_sessoin_id is the id of the session of another user to be updated; The session_id () function can be used without parameters to obtain the sessionid of the current user, however, after session-start (), use $ _ COOKIE [session_name ()];
Session_start ();
... // Operate on the session to be operated.
} // The end of loop Processing
Session_write_close ();
Session_id ($ my_session_id); // restores the session of the current user.
Session_start ();