在application.ini中定义模块布局

时间:2010-07-02 11:58:17

标签: php zend-framework

我正在尝试在没有Zend Framework应用程序的情况下设置模块,并且想知道如何配置模块以使用自己的布局脚本。

我希望在我的application.ini文件中定义它,但我不知道该怎么做......

我试过了:

resources.frontController.controllerDirectory = APPLICATION_PATH "/controllers"
resources.frontController.params.displayExceptions = 0
resources.frontController.moduleDirectory = APPLICATION_PATH "/modules"
resources.modules.layout.layout = "dietplan"
resources.modules.layout.layoutPath = APPLICATION_PATH "/layouts/scripts/"

resources.layout.layoutPath = APPLICATION_PATH "/layouts/scripts/"

这......

resources.frontController.controllerDirectory = APPLICATION_PATH "/controllers"
resources.frontController.params.displayExceptions = 0
resources.frontController.moduleDirectory = APPLICATION_PATH "/modules"
dietplan.resources.layout.layout = "dietplan"
dietplan.resources.layout.layoutPath = APPLICATION_PATH "/layouts/scripts/"

resources.layout.layoutPath = APPLICATION_PATH "/layouts/scripts/"

但我无处可去。

有什么想法吗?

1 个答案:

答案 0 :(得分:1)

默认情况下不可行,您需要一个Controller插件。非常好的教程:

Zend Layout + Modules