Zend framework Zend framework上出现致命错误
我已经在Ubuntu 10.10上安装了Zend framework。 我刚刚用zend工具创建了一个项目 但是,如果我看到,我会得到以下错误Zend framework Zend framework上出现致命错误,zend-framework,ubuntu,Zend Framework,Ubuntu,我已经在Ubuntu 10.10上安装了Zend framework。 我刚刚用zend工具创建了一个项目 但是,如果我看到,我会得到以下错误 Fatal error: Uncaught exception 'Zend_Db_Adapter_Exception' with message 'Configuration array must have a key for 'password' for login credentials' in /usr/share/php/libzend-fr
Fatal error: Uncaught exception 'Zend_Db_Adapter_Exception' with message
'Configuration array must have a key for 'password' for login credentials'
in /usr/share/php/libzend-framework-php/Zend/Db/Adapter/Abstract.php:284 Stack trace:
#0 /usr/share/php/libzend-framework-php/Zend/Db/Adapter/Abstract.php(183): Zend_Db_Adapter_Abstract->_checkRequiredOptions(Array)
#1 /usr/share/php/libzend-framework-php/Zend/Db.php(265): Zend_Db_Adapter_Abstract->__construct(Array)
#2 /usr/share/php/libzend-framework-php/Zend/Application/Resource/Db.php(142): Zend_Db::factory('PDO_MYSQL', Array)
#3 /usr/share/php/libzend-framework-php/Zend/Application/Resource/Db.php(154): Zend_Application_Resource_Db->getDbAdapter()
#4 /usr/share/php/libzend-framework-php/Zend/Application/Bootstrap/BootstrapAbstract.php(680): Zend_Application_Resource_Db->init()
#5 /usr/share/php/libzend-framework-php/Zend/Application/Bootstrap/BootstrapAbstract.php(623): Zend_Application_Bootstrap_BootstrapAbstract->_executeResource('db')
#6 /usr/share/php/libzend-framewor in /usr/share/php/libzend-framework-php/Zend/Db/Adapter/Abstract.php on line 284
谁能告诉我怎么解决这个问题吗
提前感谢。Zend Framework Db Adapter在数据库配置参数中搜索用户名和密码字段,如果找不到,则返回该错误 您可以不使用密码连接到数据库,但必须将参数密码添加到配置中,只需将其保留为空即可: resources.db.adapter=MYSQLI resources.db.params.host=localhost resources.db.params.username=root resources.db.params.password=
搜索该错误消息会得到您想要的结果。第一个打击是。。。如果您试图通过一个无密码的MySQL用户帐户进行连接,我认为ZF不支持这种方式,除非您想尝试一个空密码值