Re: PEAR DB Error

From: Date: Mon, 23 Apr 2001 20:24:17 +0000
Subject: Re: PEAR DB Error
References: 1  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-75@lists.php.net to get a copy of this message
Hi, Chris! /Mon, 23 Apr 2001 13:05:58 -0500/ you wrote: CM> On reading through the archives, I found this tidbit. CM> $dbh = DB::connect($dsn, array("debug" => 2)); CM> in a message from Stig SФther Bakken CM> On adding the debug level 2, I get: CM> Warning: Failed opening 'DB/dsn.php' for inclusion CM> (include_path='/usr/local/lib/php/pear') in DB.php on line 230 It seems that you're trying to call DB::connect in function, where variable $dsn isn't visible. You should add "Global $dsn;" in your function or use it as function parameter. -- Best regards, Ed

« previous php.pear.general (#75) next »