[thelist] Saving and Destroying Session IDs and Vars with PHP5

Pringle, Ron RPringle at aurora-il.org
Tue Mar 6 10:26:13 CST 2007


Hello all-

I am developing an admin section of my site that has a multi-page form on it. I use a session id and use session variables for storing and passing the form data from page to page, until it is finally submitted to the database.

After a successful submission, I want to destroy all the session variables, but I need to leave the session id in place. Calling session_unset and session_destroy clears everything out, including the session id, which then forces the user to log back into the admin section.

Do I have to manually destroy each session variable to get around this? Or is there a way to regenerate the session id and destroy the old session and its related session data?

Ron



More information about the thelist mailing list