Page 1 of 1

Classes and session vars

Posted: Mon Nov 17, 2003 11:22 pm
by tekdek
hey got 2 questions

1. when do objects die? do they have a time out after they are created form a class? is there a way to kill them?

2. is there a way to get all the session vars form all the users and put them in to a big array?

thanks in advance

Posted: Tue Nov 18, 2003 8:11 am
by Weirdan
1. Objects die when GC decides to kill them. (GC - Garbage Collector). GC kills the objects which have no references to it.

2. Do you really need it? Sessions are intended to store the data on per-user basis... though you can implement custom session handling ([php_man]session_set_save_handler[/php_man]).