您的位置:首页 > 其它

zf2环境设置

2015-10-20 19:18 363 查看
一、关于环境

修改apache目录下的httpd.conf

1.SetEnv ZF2_PATH “d:/myphp/www/zf2library”

2.修改 AllowOverride none 为AllowOverride All

二、有关文件描述

module.config.php文件中定义了模块中可以访问的各类路径信息定义:

'router' :路由定义,确定哪些action能被执行

'service_manager': 确定模块需要加载哪些服务

'factories':

layout.phtml 文件在module/application/config/module.config.php中定义

'view_manager' => array(
'display_not_found_reason' => true,
'display_exceptions'       => true,
'doctype'                  => 'HTML5',
'not_found_template'       => 'error/404',
'exception_template'       => 'error/index',
'template_map' => array(
'layout/layout'           => __DIR__ . '/../view/layout/layout.phtml',
'application/index/index' => __DIR__ . '/../view/application/index/index.phtml',
'error/404'               => __DIR__ . '/../view/error/404.phtml',
'error/index'             => __DIR__ . '/../view/error/index.phtml',
),
'template_path_stack' => array(
__DIR__ . '/../view',
),
),


view_manager:各类视图模板文件定义,系统默认layout.phtml 可以修改
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: