I would like for the session to be killed as soon as the visitor exits the browser (close tab or browser) or navigates away from any page related to the site, I create the session in the header which is an includes.
Thanks
PHP
Last Comment
Ray Paseur
8/22/2022 - Mon
Ray Paseur
The session will only be killed if the client closes the last instance of the browser or if the browser is idle for (about) 24 minutes. The last instance means the last tab and the last window. That is just the way it works. Try to design your app so it will work in consonance with the existing guidelines and you will be OK.
prowebinteractiveinc
ASKER
what if I expire the session after lets say 10-15min of inactivity, then if the user is on the public site, it simply renews the session_id(); otherwise if the user is in a logged in area, it will log him out, sounds like that function would be more secure..