apprentice,
What is the var dump output on $config->db? Check the format of it against the proper format listed in the reference manual(http://framework.zend.com/manual/en/zend.db.html#zend.db.adapter.connecting.factory-config).
Regards,
Duo
On Oct 4, 2009, at 6:16 AM, W Itch wrote:
Fatal error: Uncaught exception 'Zend_Db_Exception' with message 'Adapter name must be specified in a string'
I've been googling this problem but can't find any hints to follow. Can somebody help me fix this Error?
The code that is causing this error is this:
Bootstrapprotected function _initRegDatabase()
{
$config = Zend_Registry::get('config');
$db = Zend_Db::factory($config->db); // This line seems to cause the Error!
Zend_Db_Table_Abstract::setDefaultAdapter($db);
Zend_Registry::set('db', $db);
}
/apprentice
没有评论:
发表评论