php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #5121 session_module_name() does not change session module
Submitted: 2000-06-19 12:56 UTC Modified: 2000-07-10 19:15 UTC
From: troels at arvin dot dk Assigned:
Status: Closed Package: Session related
PHP Version: 4.0 Latest CVS (19/06/2000) OS: Red Hat Linux 6.2
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
24 - 15 = ?
Subscribe to this entry?

 
 [2000-06-19 12:56 UTC] troels at arvin dot dk
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.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-07-10 19:15 UTC] troels at arvin dot dk
The problem seems to have been corrected in CVS.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 24 22:01:30 2024 UTC