From:             [EMAIL PROTECTED]
Operating system: Windows XP
PHP version:      4.1.2
PHP Bug Type:     Session related
Bug description:  Use of $_SESSION to set variable doesn't save variable

Following the 'Session handling' documentation and expriencing problems
with a production script, I wrote the following test script:

test.php:
<?php
session_start();
echo "Session ID : ".session_id()."<BR>\r\n";
if( !isset( $_SESSION['Test'] ) )
{
        $_SESSION['Test'] = "bla bla bla";
        echo "Defined : ".$_SESSION['Test']."<BR>\r\n";
}
else
{
        echo "Existing : ".$_SESSION['Test']."<BR>\r\n";
}
//session_write_close();
?>

which I expect to set the 'Test' session variable on the first call to the
page and then return the 'Test' session variable on subsequent calls to
the script.

This works FINE with PHP 4.1.1 but DOES NOT WORK with PHP 4.1.2 (though
the session ID is the same). I had to revert to the old
'session_register()' function for the script to work in PHP 4.1.2,
$HTTP_SESSION_VARS not working either.

Any clue ?

Ce.D
-- 
Edit bug report at http://bugs.php.net/?id=16585&edit=1
-- 
Fixed in CVS:        http://bugs.php.net/fix.php?id=16585&r=fixedcvs
Fixed in release:    http://bugs.php.net/fix.php?id=16585&r=alreadyfixed
Need backtrace:      http://bugs.php.net/fix.php?id=16585&r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=16585&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=16585&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=16585&r=notwrong
Not enough info:     http://bugs.php.net/fix.php?id=16585&r=notenoughinfo
Submitted twice:     http://bugs.php.net/fix.php?id=16585&r=submittedtwice

Reply via email to