Re: confusing problem w/sessions

From: Date: Mon, 20 Aug 2001 12:52:53 +0000
Subject: Re: confusing problem w/sessions
Groups: php.general 
Request: Send a blank email to php-general+get-63498@lists.php.net to get a copy of this message
start your session before sending any html output to browser check that register_globals is on if not use $HTTP_SESSION_VARS("a") instead to reference your session var assign a value after having initialiazed your var not before ---------- Original Message ---------------------------------- From: "Gabriele Biondo" <gbiondo@mac.com> Date: Mon, 20 Aug 2001 14:34:35 +0200 >Dear sirs; >i have a simple snippet of code : ><? > session_start(); > $a = 10; > session_register("a"); >?> > >i am trying to understand how do session work. > >Accessing at this document directly from the server (it is a SuSE 7.2 PE - >running PHP 4.0.4 >and apache 1.3.9) i find out the following problem: > >Warning: cannot send session cookie - headers already sent (output started >at ....) > >and > >Warning: cannot send session cache limiter - headers already sent (output >started at ....) > >The matter is that if i access this variables from another page, they seem >to be empty... > >How can i solve this little confusing problem? > >Thanks in advance > >Gabriele > > >-- >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 (#63498) next »