Someone could throw an issue at JIRA about it. It really shouldn't be tied to a specific constant name. That said, the whole point of the Zend tool component is to work with a predictable generated project so it could be a deliberate simplication by design.
Paddy
Pádraic Brady
http://blog.astrumfutura.com
http://www.survivethedeepend.com
OpenID Europe Foundation Irish Representative
From: Hector Virgen <djvirgen@gmail.com>
To: Brenton Alker <brenton@tekerson.com>
Cc: huajun qi <qihjun@gmail.com>; fw-mvc@lists.zend.com
Sent: Wed, October 28, 2009 10:49:11 PM
Subject: Re: [fw-mvc] how to use APPLICATION_ENV
The default error.phtml created by zf.sh tests the APPLICATION_ENV constant to determine if exception information should be displayed. If it's set to "development", then exception information is displayed. Is there a better way for it to determine this without using the constant?
--
Hector
Paddy
http://blog.astrumfutura.com
http://www.survivethedeepend.com
OpenID Europe Foundation Irish Representative
From: Hector Virgen <djvirgen@gmail.com>
To: Brenton Alker <brenton@tekerson.com>
Cc: huajun qi <qihjun@gmail.com>; fw-mvc@lists.zend.com
Sent: Wed, October 28, 2009 10:49:11 PM
Subject: Re: [fw-mvc] how to use APPLICATION_ENV
The default error.phtml created by zf.sh tests the APPLICATION_ENV constant to determine if exception information should be displayed. If it's set to "development", then exception information is displayed. Is there a better way for it to determine this without using the constant?
--
Hector
On Wed, Oct 28, 2009 at 2:26 PM, Brenton Alker <brenton@tekerson.com> wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
It's not used internally, no. So, you could rename it (or not set it)
huajun qi wrote:
> I know zend defines a APPLICATION_ENV variable in the index.php file,
> but we don't see it is used explicitly. Is it used in zend source code?
without problem. The only way it is used is when you instantiate
Zend_Application you tell it which section of the config
(application.ini by default) you want to load.
You often have different sections of the config file (application.ini)
> Does it have some usage to help develop?
for each environment. By default, one for testing/staging/production.
Usually, the majority of the configuration is in production and the
others inherit from that.
You can then override values in the other sections. This can be used to
do things like override the database configuration, to use SQLite for
testing, or a separate MySQL instance for staging.
Hope that helps.
- --
Brenton Alker
PHP Developer - Brisbane, Australia
http://blog.tekerson.com/
http://twitter.com/tekerson
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkrotwAACgkQ7bkAtAithuv4UwCfYTPeVj+McP94lz4OEm0NN48x
ojcAn3IE3ofwyL2s8Q4quvR+3XBe+UEC
=AGUq
-----END PGP SIGNATURE-----
没有评论:
发表评论