Jump to content

sessions


AV1611

Recommended Posts

I'm confused by sessions...

 

I know that to access a session variable the script needs to start with session_start then I can read out $_SESSION[var].

 

as I go from page to page, each script starts with the session_start and the session var is there..

 

now,

 

I have a logout hyperlinl that simply does this:

 

session_destroy();

header('Location: index.php');

 

when I click the link, it give me this error:

 

Warning: session_destroy() [function.session-destroy]: Trying to destroy uninitialized session in C:\xampplite\htdocs\cvlb\killall.php on line 2

 

Huh?

 

Am I just very confused...???

 

 

Link to comment
https://forums.phpfreaks.com/topic/103035-sessions/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.