Fatal error - Login_Plugin_SecurityCheck not found

久未见 提交于 2020-01-22 02:18:10

问题


I am trying to implement user login using PHP/Zend. Following the example below: https://github.com/ezimuel/Authentication-and-authorization-with-ZF.git

I get the following errors when going to http://localhost/

Warning: include_once(Login/Plugin/SecurityCheck.php) [function.include-once]: failed to open stream: No such file or directory in /Library/WebServer/Documents/xxxxx/library/Zend/Loader.php on line 146

Warning: include_once() [function.include]: Failed opening 'Login/Plugin/SecurityCheck.php' for inclusion (include_path='/Library/WebServer/Documents/xxxxx/application/../library:/Library/WebServer/Documents/xxxxx/library:/Library/WebServer/Documents/xxxxx/application/modules/login/library:.:/usr/lib/php') in /Library/WebServer/Documents/xxxxx/library/Zend/Loader.php on line 146

Fatal error: Class 'Login_Plugin_SecurityCheck' not found in /Library/WebServer/Documents/xxxxx/library/Zend/Application/Resource/Frontcontroller.php on line 117

I setup the project by following the Zend Quickstart Tutorials, so my application.ini file is slightly different. Im guessing this is a simple case of the application not being able to find certain files?


回答1:


Have you got these lines in your application.ini:

resources.frontController.defaultModule = "login"
resources.frontController.params.prefixDefaultModule = "1"
resources.modules[]=
resources.frontController.moduleDirectory = APPLICATION_PATH "/modules"
resources.frontController.plugins[] = "Login_Plugin_SecurityCheck"

Also, I notice the plugin is specified in the config as Login_Plugin_SecurityCheck, but in the login module, the folder is plugins, not plugin.



来源:https://stackoverflow.com/questions/7176301/fatal-error-login-plugin-securitycheck-not-found

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!