Bug #12704 Updated: Session variables DO NOT WORK!

From: Date: Sun, 12 Aug 2001 05:49:34 +0000
Subject: Bug #12704 Updated: Session variables DO NOT WORK!
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-62967@lists.php.net to get a copy of this message
ID: 12704 Updated by: sniper Reported By: mikepc143@home.com Old Status: Open Status: Bogus Bug Type: Session related Operating System: Windows 2000, Service Pack 2 PHP Version: 4.0.6 New Comment: Please ask support questions on appropriate mailing list, found at: http://www.php.net/support.php Previous Comments: ------------------------------------------------------------------------ [2001-08-12 01:36:57] mikepc143@home.com /* class.user.php included from required file classes.php */ // class definition is as follows: class User { var $username; var $userid; var $email; var $logged_in; var $on_from; var $goto; var $time_on; var $msglock; function set_email($s) { $this->email = $s; } function get_email() { return $this->email; } function set_username($s) { $this-> username = $s; } function log_in($id,$u, $mip, $timeclock, $pri=1) { $this-> on_from = $mip; $this-> time_on = $timeclock; $this-> username = $u; $this-> guildid = $pri; $this-> userid = $id; $this-> logged_in = true; } } class Site {}; $SITE = new Site; $SITE-> wwwroot = "www.gamebaz.com"; $SITE-> droot = "D:/gamebaz/gm/"; $SITE-> libdir = $SITE-> droot . "lib"; require("$SITE->libdir/stdlib.php"); require("$SITE->libdir/dblib.php"); require("$SITE->libdir/classes.php"); require("$SITE->libdir/main_logic.php"); require("$SITE->libdir/form_validation.php"); require("$SITE->libdir/error.php"); if(!isset($this_user)) /* This code runs half the time, and the other times it doesn't I haven't been able to narrow it down I changed nothing in the include files, just all the sudden it thinks that $this_user is never registered again. */ { @session_start(); global $this_user; $this_user = new User("","","","","","","",""); @session_register("this_user"); printf("Starting new user<br>"); } ------------------------------------------------------------------------ Edit this bug report at http://bugs.php.net/?id=12704&edit=1

« previous php.dev (#62967) next »