Problem in logout

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
hatrena
Forum Newbie
Posts: 7
Joined: Thu Jan 20, 2011 5:24 am

Problem in logout

Post by hatrena »

Hi everybody.

i have created a log out page. but when i am logged out and then press BACKSPACE i will be directed to the previous page not to login page.

please help me on this to solve the problem.

thank you. :(
anantha
Forum Commoner
Posts: 59
Joined: Thu Dec 23, 2010 7:38 pm

Re: Problem in logout

Post by anantha »

in each page at the top you need to check whether a person is logged in or not...if not send them to login page in your case...
User avatar
social_experiment
DevNet Master
Posts: 2793
Joined: Sun Feb 15, 2009 11:08 am
Location: .za

Re: Problem in logout

Post by social_experiment »

At logout you can set a value in the database to 0 and your 'auth' checking should have a look at that value to see if it is set. If it is, user still logged in, else user not logged in, redirect (or take appropriate action).
“Don’t worry if it doesn’t work right. If everything did, you’d be out of a job.” - Mosher’s Law of Software Engineering
Post Reply