Fur, I know little about the application, but there is nothing wrong with being a Bootstrap object, in my opinion. Looking at my dump, it seems that Zend_Application is actually related to it. It also seems to contain the information you are looking for:
object(Bootstrap)[3] protected '_appNamespace' => string '' (length=0) protected '_resourceLoader' => object(Zend_Application_Module_Autoloader)[7] protected '_application' => object(Zend_Application)[1] protected '_classResources' => protected '_container' => object(Zend_Registry)[15] protected '_environment' => null protected '_optionKeys' => array protected '_options' => array 'phpSettings' => array 'display_startup_errors' => string '1' (length=1) 'display_errors' => string '1' (length=1) 'date' => array ... 'bootstrap' => array 'path' => string 'C:\sites\mysite\application/Bootstrap.php' (length=39) 'class' => string 'Bootstrap' (length=9) 'resources' => array 'frontController' => array ... 'modules' => array ... 'layout' => array ... 'view' => array ... 'session' => array ... 'log' => array ... 'doctrine' => array ... 'appnamespace' => string '' (length=0) 'autoloadernamespaces' => protected '_pluginLoader' => object(Zend_Loader_PluginLoader)[35]
Actually, I donβt understand why you have a problem, you have to give us some dumps.
It works when I try:
<?php class Admin_Bootstrap extends Zend_Application_Module_Bootstrap { protected function _initApp() { $app = $this->getApplication(); echo '1:'; // die(var_dump($app->getOptions())); var_dump($app->getOption('phpSettings')); $app->setOptions(array('phpSettings'=>array('date'=>array('timezone'=>'America/New York')))); echo '2:'; var_dump($app->getOption('phpSettings')); } }
This is in my layout:
<?php echo 'in layout'; $bootstrap = Zend_Controller_Front::getInstance()->getParam('bootstrap'); var_dump($bootstrap->getOptions()); ?>
This is my conclusion:
1: array 'display_startup_errors' => string '1' (length=1) 'display_errors' => string '1' (length=1) 'date' => array 'timezone' => string 'Africa/Johannesburg' (length=19) 2: array 'display_startup_errors' => string '1' (length=1) 'display_errors' => string '1' (length=1) 'date' => array 'timezone' => string 'America/New York' (length=16) in layout array 'phpSettings' => array 'display_startup_errors' => string '1' (length=1) 'display_errors' => string '1' (length=1) 'date' => array 'timezone' => string 'America/New York' (length=16)
Works great for me.
source share