Re: Pear help

From: Date: Mon, 28 Feb 2005 17:00:03 +0000
Subject: Re: Pear help
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-38707@lists.php.net to get a copy of this message
* Craig Hoffman <choffman@eclimb.net>: > I'm trying to configure my OS X box to work with PEAR. Everything > seems to be working (updating PEAR libraries, etc.) except when I run > my test script I get the following error: > > Fatal error: Cannot redeclare class db in /usr/lib/php/DB.php on line > 271 > > Here is my test script: > <?php > require 'DB.php'; Usually when you get a "Cannot redeclare class..." error, it's because it's been loaded already somewhere else -- on another file is trying to define a class of the same name. Try 'require_once "DB.php";' and see if you get the same error. If you do, check to see if you have an auto_prepend_file directive set, and if the file being prepended is defining the DB class. -- Matthew Weier O'Phinney | WEBSITES: Webmaster and IT Specialist | http://www.garden.org National Gardening Association | http://www.kidsgardening.com 802-863-5251 x156 | http://nationalgardenmonth.org mailto:matthew@garden.org | http://vermontbotanical.org

« previous php.db (#38707) next »