Re: Unregistering several variables at once -- how?

From: Date: Sat, 06 Sep 2003 17:42:52 +0000
Subject: Re: Unregistering several variables at once -- how?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-161864@lists.php.net to get a copy of this message
James Johnson wrote:
Hi, I have 15 - 20 $_SESSION vars that I want to clear when a user logs out. I've been doing it with the following code: if(session_is_registered($_SESSION['svUserID'])){ session_unregister($_SESSION['svUserID']); } But, this is tedious. Is there a better way, like session_unregister(all)?
$_SESSION = array(); -- ---John Holmes... Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/ php|architect: The Magazine for PHP Professionals – www.phparch.com

« previous php.general (#161864) next »