invalid link resource after deserialization

From: Date: Tue, 02 Apr 2002 16:30:00 +0000
Subject: invalid link resource after deserialization
Groups: php.db 
Request: Send a blank email to php-db+get-18132@lists.php.net to get a copy of this message
Hi all, I have a problem that I loose connection_id (i.e. it gets set to 0) when I propagate object through session. This results in an error message when I use this connection. Warning: Supplied argument is not a valid PostgreSQL link resource Object has member variable $db which is of PEAR_DB type. method: function openDB() { $this->db = DB::connect($dsn, true); if (DB::isError($db)) { die($db->getMessage()); } } So every time I deserialize this object from session I have to call openDB method first. Thanks, Hrvoje

« previous php.db (#18132) next »