php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #7107 Bug with changing session name
Submitted: 2000-10-09 19:56 UTC Modified: 2000-10-16 14:22 UTC
From: richard dot heyes at heyes-computing dot net Assigned:
Status: Closed Package: Session related
PHP Version: 4.0.2 OS: RHL6.1, Apache 1.3.12
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: richard dot heyes at heyes-computing dot net
New email:
PHP Version: OS:

 

 [2000-10-09 19:56 UTC] richard dot heyes at heyes-computing dot net
Whenever I change the session.name variable like this:

ini_set('session.name', 'SESSIONID');

I get this intermittent error:

Warning: Delimiter must not be alphanumeric or backslash in func.database.inc on line 101

The offending code on line 101 is this:

if(preg_match('/^select/i', $sql)) $rows = db_num_rows($result);

Although it's not limited to this code, when using the PEAR db layer it came a cropper on that too. The code there also contained a preg function. (Line 331 of DB.php IIRC)

If I don't change the session.name variable, the error never happens.

Configure line:

'./configure' '--with-apache=../httpd' '--with-mysql' '--with-ftp' '--with-config-file-path=/www/conf' '--enable-dbase' '--with-pgsql=/usr/include/pgsql' '--with-mcrypt' '--with-imap' '--enable-sockets'

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-10-16 14:22 UTC] sas@php.net
The proper way to change the session name is to use session_name().

If there are any other problems related to ini_set(), please file a separate bug report.

Thank you.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Mon Jul 07 07:01:33 2025 UTC