Viewing topic:logout code needed for the reg and login script
Page: 1
Topic post 06-06-2008 - 20:54
i am wondering how i can create a logout script for the above tutorial
Topic post 06-06-2008 - 23:39
That's fairly easy. You are logged in because the SESSION exists, so the only thing that needs to be done is deleting the session. You can delete the session with the following snippet:

session_start();

// Delete the sessions
session_destroy();

echo 'You are nog logged out.';

Just save it to logout.php and when opening this page the user will be logout

©Copyrights Combined Minds. All rights reserved 2006 - 2008 : Disclaimer
Realized by www.Minna-Media.com