getOptions()); Zend_Registry::set('config', $config); return $config; } protected function _initDb() { $c = Zend_Registry::get('config'); try { $db = Zend_Db::factory($c->profil->db->metier); } catch ( Exception $e ) { echo "Database !\n"; exit; } /** * Set the default adapter to use with all model */ Zend_Db_Table::setDefaultAdapter($db); } protected function _initCache() { /*if ( APPLICATION_ENV!='development' ) { //MetadataCache pour la base de données $frontendOptions = array( 'lifetime' => 14400, 'automatic_serialization' => true ); $backendOptions = array(); $cache = Zend_Cache::factory('Core','Apc', $frontendOptions, $backendOptions); Zend_Db_Table_Abstract::setDefaultMetadataCache($cache); }*/ } }