Is there a helper method/object/methodology for getting a reference to a Zend_Application
's config resource?
I know I can do something like
$config = new Zend_Config_Ini($file, $environment);
but that's going to reload/parse the config file. I'm looking for a way to peek at the given configuration value for a running Zend_Application
.
The larger issue I'm trying to solve is I want a Zend_Queue
to use the same database settings as my default database resource. If there's a more "Zend Like" way of achieving this other than "get reference to config, read resource values" please feel free to share that as well!
Zend_Queue
there is code in
Zend_Queue_Adapter_Db
__constructif (isset($this->_options['dbAdapter']))
so u can do thomething like thisbecause standart
Zend_Application_Resource_Db
can use config optionresources.db.isDefaultTableAdapter = true
or u can put db adapter in registry and get it from there at any place