session_unset()
Release all $_SESSION variables currently created in memory, but do not delete the session file and do not release the corresponding session
id
session_destroy()
Delete the current user corresponding session file and release the session
id, the content of the $_SESSION variable in the memory is still retained
. Therefore, to release all the resources of the user's session, the following code needs to be executed in sequence: