Plugin "Multidb" lösen, wenn mein Projekt versuche ich anfangen die Folowing Fehlermeldung:kann nicht
Fatal error: Uncaught exception 'Zend_Application_Bootstrap_Exception' with message 'Unable to resolve plugin "multidb"; no corresponding plugin with that name' in C:\xampp\php\PEAR\Zend\Application\Bootstrap\BootstrapAbstract.php:330
Stack trace:
#0 C:\xampp\php\PEAR\Zend\Application\Bootstrap\BootstrapAbstract.php(314): Zend_Application_Bootstrap_BootstrapAbstract->getPluginResource('multidb')
#1 C:\xampp\php\PEAR\Zend\Application\Bootstrap\BootstrapAbstract.php(673): Zend_Application_Bootstrap_BootstrapAbstract->hasPluginResource('multidb')
#2 C:\xampp\php\PEAR\Zend\Application\Bootstrap\BootstrapAbstract.php(622): Zend_Application_Bootstrap_BootstrapAbstract->_executeResource('multidb')
#3 C:\xampp\php\PEAR\Zend\Application\Bootstrap\BootstrapAbstract.php(579): Zend_Application_Bootstrap_BootstrapAbstract->_bootstrap('multidb')
#4 C:\xampp\htdocs\modular_zf\application\Bootstrap.php(41): Zend_Application_Bootstrap_BootstrapAbstract->bootstrap('multidb')
#5 C:\xampp\php\PEAR\Zend\Application\Bootstrap\BootstrapAbstract in C:\xampp\php\PEAR\Zend\Application\Bootstrap\BootstrapAbstract.php on line 330
bootstrap.php (ab Zeile 39)
protected function _initDatabases()
{
$this->bootstrap('multidb'); // line 41
$resource = $this->getPluginResource('multidb');
$databases = Zend_Registry::get('config')->resources->multidb;
foreach ($databases as $name => $adapter)
{
$db_adapter = $resource->getDb($name);
Zend_Registry::set($name, $db_adapter);
}
}
Anwendung .ini
[bootstrap]
...
...
;Database settings
resources.multidb.front_db.adapter = "pdo_mysql"
resources.multidb.front_db.host = 127.0.0.1
resources.multidb.front_db.username = admin
resources.multidb.front_db.password = admin
resources.multidb.front_db.dbname = modular_zfdb
resources.multidb.front_db.default = true
...
...
Ich habe excatly die gleiche Nachricht ("Kann Plugin nicht aufzulösen ...) in einem anderen ähnlichen Projekt
danke.
Welche Version von Zend Framework verwenden Sie? – dbrumann
verwende ich ZF v1.11.4, sollte ich die neueste Version verwenden? – Salem
Aktualisieren auf eine neuere Version ist ratsam, aber wahrscheinlich nicht die Quelle Ihres Problems. Versuchen Sie, nach der Plugin-Ressource zu suchen, indem Sie '$ this-> hasPluginResource ('multidb')' anstelle von '$ this-> bootstrap ('multidb')' verwenden. – dbrumann