Re: HTTP_SESSION_VARS]

From: Date: Thu, 08 Nov 2001 17:51:46 +0000
Subject: Re: HTTP_SESSION_VARS]
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-73925@lists.php.net to get a copy of this message
Another thing came to my mind. From the docs : "All registered variables are serialized after the request finishes. Registered variables which are undefined are marked as being not defined. On subsequent accesses, these are not defined by the session module unless the user defines them later." It is a theory and you will say if it true or false. So you trun off register globals but use $username from the form...hmmm but it has no value because you have to use $HTTP_GET_VARS/$HTTP_POST_VARS. The text from the docs says it cleary that undefined but registered variables are not stored. Is this your case? Best regards, Andrey Hristov IcyGEN Corporation http://www.icygen.com BALANCED SOLUTIONS ----- Original Message ----- From: "Ron Clark" <clarkron@mail.armstrong.edu> To: <php-general@lists.php.net> Sent: Thursday, November 08, 2001 7:37 PM Subject: Re: [PHP] HTTP_SESSION_VARS] > Andrey Hristov wrote: > > > > Can you place a snippet of your code? Remove the things which are confidential. > > > > Andrey Hristov > > IcyGEN Corporation > > http://www.icygen.com > > BALANCED SOLUTIONS > > > In file called by the login form. > > session_start(); > session_register('usertype'); > session_register('username'); > > This file redirects the user to user.php where > session_start(); > $username = $HTTP_SESSION_VARS[username]; > print "username $username"; > only prints the string username > print_r($HTTP_SESSION_VARS); > only prints Array() > > Looking at the session files: > If register_globals is off- > > !username|!usertype| > > If register_globals is on- > |b:1;username|s:8:"clarkron"|usertype|s:7:"Faculty";user_is_logged_in > > Ron Clark > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > >

« previous php.general (#73925) next »