-- Stephan Stapel <[EMAIL PROTECTED]> wrote
(on Monday, 25 June 2007, 05:27 PM +0200):
> I guess a lot of you have the problem to have code that is used within 
> multiple environments, a (local) environment for development, another 
> for testing and a third for production.
> 
> Usually, some things like database configuration differ between these 
> environments. I was asking myself if anyone has a smart solution for a 
> flexible configuration such that no additional files have to be renamed/ 
> moved when deploying.
> 
> If someone has a good solution, would he/she like to share it?

Look through the Zend_Config documentation. Zend_Config has concepts of
both sections and inheritance, allowing you to create config files that
can be used in multiple contexts, or with contents that will differ
based on situation data. In particular, look at the Zend_Config_Ini
docs, http://framework.zend.com/manual/en/zend.config.adapters.ini.html,
which shows an example of production vs. staging configurations for a
database adapter.

-- 
Matthew Weier O'Phinney
PHP Developer            | [EMAIL PROTECTED]
Zend - The PHP Company   | http://www.zend.com/

Reply via email to