Just a guess but would using session_register(myvar); instead of
registering directly to the global list make any difference?


-----Original Message-----
From: Joel Alexandre [mailto:[EMAIL PROTECTED]] 
Sent: Monday, February 25, 2002 9:39 AM
To: Lista de PHP
Subject: [PHP] Using sessions


i'm having some trouble using sessions.

first of all i have to use php 4.0.6.

When i use $HTTP_SESSION_VARS, the session variable isn't
being saved.

for example:
if(!isset($HTTP_SESSION_VARS['id'])){
        $HTTP_SESSION_VARS['id'] = 0;   
}
else{
        $HTTP_SESSION_VARS['id']++;
}
echo $HTTP_SESSION_VARS['id'];
 
every time i refresh the browser it returns 0.
i have version 4.1.6(i tink. it's the last one)at home and it works
fine.

but if i use the session_register it all works ok.


i've tried to use global $HTTP_SESSION_VARS but nothing changed.

could someone help

thanks

Joel Alexandre
Lisboa
Portugal


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to