Re: [PHP] newbie: using sessions
On Wed, 13 Mar 2002, Faisal Abdullah wrote: > Don't you have to assign the login value to the session variable first? > > session_start(); > $login = $HTTP_POST_VARS("login"); > session_register("login"); It's the same. Saludos... :-) Porqué usar una base de datos relacional cualquiera, si podés usar PostgreSQL? - Martín Marqués |[EMAIL PROTECTED] Programador, Administrador, DBA | Centro de Telematica Universidad Nacional del Litoral - -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] newbie: using sessions
Don't you have to assign the login value to the session variable first? session_start(); $login = $HTTP_POST_VARS("login"); session_register("login"); > How are you using you're session? Are you registering the variable for > later use? > > session_start(); > session_register("login"); > > $login = $HTTP_POST_VARS['login']; > > That's it! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] newbie: using sessions
On Mar 12 Mar 2002 06:28, you wrote: > Hi i can't get the session variables working. > > When I get something like > $_SESSION['Login']=$HTTP_POST_VARS['login']; > on the first page, and i go with a link to an other php page. > When then try to get $_SESSION['Login'] again it is empty. > > How comes? How are you using you're session? Are you registering the variable for later use? session_start(); session_register("login"); $login = $HTTP_POST_VARS['login']; That's it! -- Porqué usar una base de datos relacional cualquiera, si podés usar PostgreSQL? - Martín Marqués |[EMAIL PROTECTED] Programador, Administrador, DBA | Centro de Telematica Universidad Nacional del Litoral - -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] newbie: using sessions
Have you started session? And you have to register session variables as well. Try this: session_start(); $session_login = $HTTP_POST_VARS['login']; session_register("session_login"); At the other page, where you want to output the variable, you must also start session. session_start(); echo $session_login; Regards, Faisal On Tuesday 12 March 2002 17:28, you wrote: > Hi i can't get the session variables working. > > When I get something like > $_SESSION['Login']=$HTTP_POST_VARS['login']; > on the first page, and i go with a link to an other php page. > When then try to get $_SESSION['Login'] again it is empty. > > How comes? > > > Maarten Weyn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] newbie: using sessions
Hi i can't get the session variables working. When I get something like $_SESSION['Login']=$HTTP_POST_VARS['login']; on the first page, and i go with a link to an other php page. When then try to get $_SESSION['Login'] again it is empty. How comes? Maarten Weyn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php