Re: [AUTH]container DB

From: Date: Fri, 15 Mar 2002 14:15:53 +0000
Subject: Re: [AUTH]container DB
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-4986@lists.php.net to get a copy of this message
On Thu, 14 Mar 2002 12:43:50 -0000, Pierre-Alain Joye wrote: > function _connect($dsn) > { > $this->db = DB::Connect($dsn); > > if (DB::isError($this->db)) { > return new PEAR_Error("The given dsn was not valid in file " . >__FILE__ . " at line " . __LINE__, > 41, > PEAR_ERROR_DIE, > null, > null > ); > } else { > return true; > } > } I'm not sure if this will work: If $dsn is not a string or an array, the database connection will fail, since PEAR DB expects the data source name either to be a string containing the connect information or an array containg the elements. What I intend with the current _connect() is, to provide the ability to pass already existing database connection pointers to PEAR Auth in order to reuse existing connections. Or did I miss something intentional? - Martin

« previous php.pear.dev (#4986) next »