Bug #9194 Updated: Objects not properly stored as session variables
| From: | jmoore@php.net | Date: | Mon, 16 Apr 2001 09:27:25 +0000 |
| Subject: | Bug #9194 Updated: Objects not properly stored as session variables | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-51645@lists.php.net to get a copy of this message | ||
ID: 9194
Updated by: jmoore
Reported By: ltning@anduin.net
Old-Status: Feedback
Status: Closed
Bug Type: Class/Object related
PHP Version: 4.0.4pl1
Assigned To: andre
Comments:
Please provide code and reopen bug report. This bug report is getting old and has been waiting for
your reduced code fragment for over a month.
- James
Previous Comments:
---------------------------------------------------------------------------
[2001-02-20 00:44:04] andre@php.net
Please provide a reduced code fragment (<15 lines) producing
this behaviour.
Put no database queries etc. in it and rely on no external
files/functions to ensure that we can reproduce it easily
unless the problem is not directly related to some db (or
similar) function.
---------------------------------------------------------------------------
[2001-02-09 11:00:20] ltning@anduin.net
Look at
http://mail2.anduin.net/index.phps for sourcecode
of failing page.
http://mail2.anduin.net/index.php to test, use
test/test as username/password.
Bug is as follows:
I define the class "user", call session_start(), create an instance of the object called
$currentuser, register this variable using session_register() (i tried doing this both before and
after the instancination). Upon creating, the object sets some internal variables in its
constructor, like "fullname".
When loading the page again, having the session-id in PHPSESSID, the object shows up as existing,
but trying to call a method or view a property fails with the message:
Fatal error: The script tried to execute a method or access a property of an incomplete object.
Please ensure that the class definition user of the object you are trying to operate on was loaded
_before_ the session was started in /home/ltning/webmail2/index.php on line 34
I see this bug has been reported before and considered fixed, but it doesn't seem to be.
Running latest (4.04pl1) PHP.
best regards,
Eirik Overby
---------------------------------------------------------------------------
ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=9194&edit=2