Problem setting up mdb2
| From: | Mark Steudel | Date: | Tue, 27 Jun 2006 21:36:10 +0000 |
| Subject: | Problem setting up mdb2 | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-24493@lists.php.net to get a copy of this message | ||
I'm trying to setup mdb2 for the first time and am getting the following
error:
MDB2 Error: not found
Here's the code setting it up.
require 'MDB2.php';
$dsn = array(
'phptype' => 'mysql',
'username' => DB_USER,
'password' => DB_PASS,
'hostspec' => 'localhost',
'database' => DB_NAME,
);
$db =& MDB2::connect($dsn);
if (PEAR::isError($db)) {
die($db->getMessage());
}
If I print out the dsn array I see the correct values.
I'm running it on a php5 and mysql5 box.
Thanks, Mark
-----------------------------------------
Mark Steudel
NetRiver
Web and Application Developer
555 Dayton St.
Suite A
Edmonds, WA 98020
w: http://www.netriver.net
p: 425.741.7014