问题描述
使用以下命令尝试部署骨架应用程序时:
When trying to deploy the skeleton application using the following commands:
git clone git://github.com/zendframework/ZendSkeletonApplication.git
cd ZendSkeletonApplication
php composer.phar self-update
php composer.phar install
我收到以下错误:
PHP致命错误:未捕获异常'Zend\\ServiceManager\\在\\ home \\ web / www / zftests / ZendSkeletonApplication / vendor / zendframework / zendframework中,提供抽象工厂必须是抽象工厂或抽象工厂接口的实例的类名\\\Exception\\InvalidArgumentException' /library/Zend/ServiceManager/ServiceManager.php:302\\\
Stack trace:\\\
#0 /home/web/www/zftests/ZendSkeletonApplication/vendor/zendframework/zendframework/library/Zend/ServiceManager/Config.php(126 ):Zend\\\ServiceManager\\ServiceManager-> addAbstractFactory(' Zend\\\Cache\\Serv ...')\\\
#1 /home/web/www/zftests/ZendSkeletonApplication/vendor/zendframework/zendframework/library/Zend/ModuleManager/Listener/ServiceListener.php( 223):Zend\\\ServiceManager\\Config-> configureServiceManager(Object(Zend\\\ServiceManager\\\ServiceManager))\\\
#2 [internal function]:Zend\\ModuleManager \\Listener\\ServiceListener-> onLoadModulesPost(Object(Zend\\\ModuleManager\\\ModuleEvent))\\\
#3 / home / web / www / zftests / ZendSkeletonApplication / vendor / zendframework / zendframework / library在/home/web/www/zftests/ZendSkeletonApplication/vendor/zendframework/zendframework/library/Zend/ServiceManager/ServiceManager.php第302行
推荐答案
这个工作很好。问题是ZF2.5框架中缺少两个文件。
This worked just fine. The problem is that there are two files missing from the ZF2.5 Framework.
'Zend\Cache\Service\StorageCacheAbstractServiceFactory',
'Zend\Log\LoggerAbstractServiceFactory',
谢谢Gary
这篇关于ZF2框架应用程序抛出500错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!