Simple Login logout system using php

Must Read : Simple Login logout system using php

Login and logout system is the most important thing for the user management, session management is one important thing for manage the user for the whole time of login time. for that we have to use session for this. it should have 5 files for this. we have to fetch the same value for the user and check the session and register the session value. and make destroy for logout. let see it detail,
it should need 5 files for this login-logout system, they are
  1. login/index page
  2. datafetch/usercheck page
  3. session/check page
  4. welcome/profile page
  5. logout page

the above files must me needed for this. we can named it as our wish. let see what i done here.

database name –> wearecoders
table name –> login



in the index page we have to start the session, as the above mentioned. action is performed in login.php page.


if the session is registered then go to check the profile.php page there session.php file is included so the session is checked.


check the session value is correct or not. if the session is value is not set, then again redirect to index.php page.


assign the logout.php page in the profile.php page.


in the logout.php page, we should unset or destroy the session value as the above you seen. then locate to index.php page.
and we should have to start the session in all the page.

(Visited 98 times, 1 visits today)

Leave a Comment.