Re: [PHP] PHP 5.0. Save classes in a session. Need help now

2005-05-12 Thread Jochem Maas
Richard Lynch wrote: On Wed, May 11, 2005 5:19 pm, Oscar Andersson said: Is it possibele to save a class in a session ex. $cl = new Class(); $SESSION['this_class'] = cl; hello, Oscar - why don't you try it? notice how 'Class' is a keyword so you can't name a class 'Class' notice how if you use '$SE

Re: [PHP] PHP 5.0. Save classes in a session. Need help now

2005-05-11 Thread Richard Lynch
On Wed, May 11, 2005 6:44 pm, Dan Rossi said: > I've done this by serializing and unserializing the the object. Its > been discussed however using shared memory, shm is a better way to do > it ? Sadly sh doesnt compile as default. Shared memory would maybe be faster, but then ALL your PHP scripts

Re: [PHP] PHP 5.0. Save classes in a session. Need help now

2005-05-11 Thread Richard Lynch
On Wed, May 11, 2005 5:19 pm, Oscar Andersson said: > Is it possibele to save a class in a session > > ex. > > $cl = new Class(); > $SESSION['this_class'] = cl; Yes, but... You'd have to actually use $cl in that last line, and you need to require the file that defines the class definition *BEFORE

Re: [PHP] PHP 5.0. Save classes in a session. Need help now

2005-05-11 Thread Dan Rossi
I've done this by serializing and unserializing the the object. Its been discussed however using shared memory, shm is a better way to do it ? Sadly sh doesnt compile as default. On 12/05/2005, at 10:19 AM, Oscar Andersson wrote: Is it possibele to save a class in a session ex. $cl = new Class()

[PHP] PHP 5.0. Save classes in a session. Need help now

2005-05-11 Thread Oscar Andersson
Is it possibele to save a class in a session ex. $cl = new Class(); $SESSION['this_class'] = cl; -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php