Question about The PHP Group PHP

1 Answer

Clarification thanx for replying .can you suggest me how to use n implement cookies for logout script.i was trying it like --on logout ,i was destroying session variables by deleting data in variables (like username and password),then explorer should not direct to user profile.plz help me.

Posted by on

1 Answer

  • Level 1:

    An expert who has achieved level 1.

  • Contributor
  • 4 Answers

Are you saying you're switching from a session variable to a cookie?

delete the cookie altogether by setting the expiration to a time in the past (negative value). don't forget that you'll then have to reload a page in order to reread the cookie data.

so if you have a cookie with a logged_in value = true, and you set it to logged_in value = false, you're still logged_in = true, until you reload that page (or another page) and it rereads the cookie data and now determines that logged_in = false.

make sense? write the logged_in=false to the cookie, then force a url redirection to reload the page is my suggestion.

Posted on Apr 04, 2009

1 Suggested Answer

6ya6ya
  • 2 Answers

SOURCE: I have freestanding Series 8 dishwasher. Lately during the filling cycle water hammer is occurring. How can this be resolved

Hi,
a 6ya expert can help you resolve that issue over the phone in a minute or two.
best thing about this new service is that you are never placed on hold and get to talk to real repairmen in the US.
the service is completely free and covers almost anything you can think of (from cars to computers, handyman, and even drones).
click here to download the app (for users in the US for now) and get all the help you need.
goodluck!

Posted on Jan 02, 2017

Add Your Answer

Uploading: 0%

my-video-file.mp4

Complete. Click "Add" to insert your video. Add

×

Loading...
Loading...

Related Questions:

1 Answer

How to logout from facebook


Hi,

If you wish the log out of Facebook, kindly click the "Account" tab at the top-right of the Facebook page and select "Logout" from the drop-down menu. (See attached image)
87837ad.png
For more help and clarifications, please feel free to reply to this post.

Hope this solves your problem. Thanks for using FixYa.

Mar 23, 2011 | Facebook Social Network

3 Answers

How do i sign out


Hi,

If you wish the log out pr sign out of your Facebook account, click the "Account" tab at the top-right of the Facebook page and select "Logout" from the drop-down menu. (See attached image)
87837ad.png

For more help and clarifications, please feel free to reply to this post.
Hope this solves your problem. Thanks for using FixYa.

Mar 19, 2011 | Facebook Social Network

2 Answers

|I cannot get into my facebook account it only goes to my granddaughters account on my computer. (She has used my computer.)


Just log her out using the 'account' link at the top right of the page, and log yourself in. Since the computer saves the cookies (or session) from when your granddaughter logged in, it is automatically using her profile.

Mar 03, 2011 | Facebook Social Network

1 Answer

I cannot access my facebook account. my sons keeps coming up as he used the computer last


Hi,
To access your Facebook account, you will have to logout of your son's account.

To do this, kindly click the "Account" tab at the top-right of your son's Facebook page and select "Logout" from the drop-down menu. (See attached image)
87837ad.png
Then login to your account by entering your id and password. For more help and clarifications, please feel free to reply to this post.

Hope this solves your problem. Thanks for using FixYa.

Feb 27, 2011 | Facebook Social Network

2 Answers

How can i log out from face book


Hi,

If you wish the log out of your Facebook account, kindly click the "Account" tab at the top-right of the Facebook page and select "Logout" from the drop-down menu. (See attached image)
87837ad.png

For more help and clarifications, please feel free to reply to this post.

Hope this solves your problem. Thanks for using FixYa.

Feb 11, 2011 | Facebook Social Network

2 Answers

How can i logout from facebook,while running mozilla firefox?


Hi Meena,

If you wish the log out of the Facebook account, kindly click the "Account" tab at the top-right of the Facebook page and select "Logout" from the drop-down menu. (See attached image)
87837ad.png
To login to your account again, enter your id and password. For more help and clarifications, please feel free to reply to this post.

Hope this solves your problem. Thanks for using FixYa.

Feb 03, 2011 | Facebook Social Network

2 Answers

My granddaughter used my computer to view her facebook page and now when I go onto facebook her page comes up instead of mine. How do I fix this problem? jkmckenzie@embarqmail.com My name is Judith...


The only problem is that her facebook account is saved in your system. Try deleting the saved cookies or delete the temporary files from the system. It will surely help.

Jan 02, 2011 | Facebook Social Network

1 Answer

I cant logout on other people,who uses my my computer.and i want to login


Hi,

If you wish the log out of the Facebook account of the person who last used your computer, kindly click the "Account" tab at the top-right of the Facebook page and select "Logout" from the drop-down menu. (See attached image)


aa7a1a5.png

Then login to your account by entering your login id and password. For more help and clarifications, please feel free to reply to this post.

Hope this solves your problem. Thanks for using FixYa.

Sep 24, 2010 | Facebook Social Network

2 Answers

Logout script with session management in php5


just create a logout.php script with the following

<?php
session_start();
session_destroy();

header("Location: index.php");
?>

Have your logout button/link/whatever just open that page which connects to the session with session_start. Session destroy does exactly what it sounds like... it unsets all session data and tells the server to end the session. The header request then just re-directs the user to whatever page you want after (just change out index.php)

Dec 30, 2008 | The PHP Group PHP

Not finding what you are looking for?
The PHP Group PHP Logo

Related Topics:

142 people viewed this question

Ask a Question

Usually answered in minutes!

Top The PHP Group Computers & Internet Experts

dhnguyen

Level 2 Expert

278 Answers

Computer Links

Level 3 Expert

2385 Answers

Mike

Level 3 Expert

4334 Answers

Are you a The PHP Group Computer and Internet Expert? Answer questions, earn points and help others

Answer questions

Manuals & User Guides

Loading...