Assume that I have this session
$_SESSION['LAST_ACTIVITY_For_Admin']
How to destroy that specific session, and not all sessions that session_destroy()
does?
thanks
Assuming you meant "variable" - exactly the same way you would "destroy" any other variable:
unset($_SESSION['LAST_ACTIVITY_For_Admin']);
References:
$_SESSION['LAST_ACTIVITY_For_Admin']= '';
or
$_SESSION['LAST_ACTIVITY_For_Admin']= NULL;
or
unset($_SESSION['LAST_ACTIVITY_For_Admin']);
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.