note 7903 added to session_destroy

From: Date: Sat, 19 Aug 2000 01:25:31 +0000
Subject: note 7903 added to session_destroy
Groups: php.notes 
Request: Send a blank email to php-notes+get-2591@lists.php.net to get a copy of this message
session_destroy() can't stop the session and clear the registered var,it just work like session_unset() in the current page. my test code: //test1.php ... <? if(!session_is_registered(var1)){ $var1=1; session_register(var1); }else echo "var1 had registered<br>\n"; $var1++; echo "var1=$var1<br>\n"; echo "id=".session_id()."<Br>\n"; ?> <a href="test2.php">test2</a> ... //test2.php ... <? session_destroy() $var1++; echo "var1=$var1<br>\n"; ?> <a href="test1.php">test1</a> ... in test1.php ,var1 still work after loaded test2.php and back,and the session_id not change! can anybody help me? http://www.php.net/manual/function.session-destroy.php

« previous php.notes (#2591) next »