PHP 4.0 Bug #5121: session_module_name() does not change session module
| From: | troels at arvin dot dk | Date: | Mon, 19 Jun 2000 10:56:40 +0000 |
| Subject: | PHP 4.0 Bug #5121: session_module_name() does not change session module | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-21714@lists.php.net to get a copy of this message | ||
From: troels@arvin.dk
Operating system: Red Hat Linux 6.2
PHP version: 4.0 Latest CVS (19/06/2000)
PHP Bug Type: Session related
Bug description: session_module_name() does not change session module
My sessions work (both file-based and mm-based), but the session module can only be changed in
php.ini.
session_module_name([string module]) is supposed to
1. Change the session module if the
optional module parameter is specified.
2. Return the name of the current session
module.
However, it seems that only part two works.
The php.ini (just this line):
session.save_handler=mm
Sample code:
<?php
$name=session_module_name('files');
session_start();
if (!isset($a))
{
session_register('a');
$a=0;
}
print "<p>You have reloaded this page $a
times.<br>Session module name: $name.</p>";
$a++;
?>
Sample output:
You have reloaded this page 3 times.
Session module name: mm.