我正在开发一个项目并具有以下项目布局:
|Project
|-Application
|-api
|-configs
|-controllers
|-models
|-modules
|-core
|-controllers
|-models
|-views
|-Bootstrap.php
|-site1
|-site2
|-site3
|-views
|-Bootstrap.php
|-Docs
|-Library
|-Public
|-.zfproject.xml
我在我的 application.ini 中使用了它来尝试将default
模块设置为core
模块:
resources.frontController.controllerDirectory = APPLICATION_PATH "/controllers"
resources.frontController.moduleDirectory = APPLICATION_PATH "/modules"
resources.frontController.defaultModule = "core"
resources.frontController.defaultControllerName = "Index"
resources.frontController.defaultAction = "index"
resources.modules[] = ""
我的问题是,由于某种原因,我无法让引导程序在模块中工作。就好像默认模块没有被更改一样。该应用程序的行为就像它一样,直到我尝试加载引导程序 - 我收到此错误:
致命错误:在第 85 行的 M:\Zend_Framework\library\Zend\Application\Resource\Modules.php 中,未捕获异常 'Zend_Application_Resource_Exception' 并带有消息“为模块“默认”找到引导文件,但未找到引导类“Default_Bootstrap””
以此错误为前缀:
Zend_Application_Resource_Exception:找到模块“默认”的引导文件,但在第 85 行的 M:\Zend_Framework\library\Zend\Application\Resource\Modules.php 中找不到引导类“Default_Bootstrap”
谁能看到我哪里出错了?
我的应用程序/Bootstrap.php 文件:
class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
{
}
我的应用程序/核心/Bootstrap.php 文件:
class Core_Bootstrap extends Zend_Application_Module_Bootstrap
{
}