Woodburn2006 Posted September 30, 2008 Share Posted September 30, 2008 this may seem like a silly question but i cannot seem to find an answer on the internet, but i have a link on my site saying 'LOGOUT' and i use sessions to dtermine a user being logged in or not, what i want to know is how to close the session when the user clicks the link? thanks Link to comment https://forums.phpfreaks.com/topic/126442-closing-sessions/ Share on other sites More sharing options...
conker87 Posted September 30, 2008 Share Posted September 30, 2008 session_destroy(); Link to comment https://forums.phpfreaks.com/topic/126442-closing-sessions/#findComment-653778 Share on other sites More sharing options...
Maq Posted September 30, 2008 Share Posted September 30, 2008 When the user clicks the link just execute that command and the session will stop. Link to comment https://forums.phpfreaks.com/topic/126442-closing-sessions/#findComment-653779 Share on other sites More sharing options...
Woodburn2006 Posted September 30, 2008 Author Share Posted September 30, 2008 cool thanks but how would i incorporate this into a link as i was to use a seperate page to unload the session i would have to somehow let the new page know which session it is going to unload? Link to comment https://forums.phpfreaks.com/topic/126442-closing-sessions/#findComment-653784 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.