Avatar of iskibinska
iskibinska
 asked on

zend framework basic problem - cannot redeclare class Zend_DB

Hi Experts,

when trying to Zend_DB:: factory  I am getting a fatal error:

Fatal error: Cannot redeclare class Zend_Db in /usr/local/zendsvr/share/ZendFramework/library/Zend/Db.php on line 33  


ini_set('display_errors', true);
 error_reporting(E_ALL);

 $library = '/usr/local/zendsvr/share/ZendFramework/library';

 set_include_path($library);
 
  require_once 'Zend/Loader.php';
  Zend_Loader::registerAutoload();
 
  echo '<h1> my ibm is running :'.Zend_Version::VERSION;
   
 
   $options = array(Zend_DB::CASE_FOLDING => Zend_DB::CASE_UPPER);

   
   $db = Zend_DB::factory('Db2',
    array(  
 
    'host'  => '127.0.0.1',
    'dbname' => 'xxxxx',
     'username' => 'xxx',
     'password' =>'xxx',
     'os' => 'i5',
    'options' => $options)
  );
 
   
   
 
 
?>
PHP

Avatar of undefined
Last Comment
iskibinska

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
dsmile

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
iskibinska

ASKER
n
Your help has saved me hundreds of hours of internet surfing.
fblack61