将应用程序启动到index.php。
$application = new Zend_Application(
APPLICATION_ENV,
APPLICATION_PATH . '/configs/application.ini'
);
有没有办法在初始化中使用多个“.ini”文件,也没有做任何引导动作?
答案 0 :(得分:1)
我在index.php中插入了这段代码,似乎有效。
require_once 'Zend/Config/Ini.php';
$config = new Zend_Config_Ini (APPLICATION_PATH . '/configs/application.ini', APPLICATION_ENV, array ('allowModifications' => true));
$config->merge (new Zend_Config_Ini (APPLICATION_PATH . '/configs/channels.ini'));
$application = new Zend_Application(
APPLICATION_ENV,
$config
);