I would like a function to run whenever a session is destroyed. I’ve looked into using session_set_save_handler but I don’t want to manually handle the storage of sessions, I just want to do a little processing when they’re destroyed. Is there any way to do this without using session_set_save_handler?
Share
The handler is pretty much the only method I think. A session can also be destroyed as part of the garbage collection and both of those can only be intercepted by using the session_set_save_handler that I know of.