ZF components are dependent on each other, Some have more dependencies then others. There is a section in the manual that describes those dependencies on a component bases.
On Wed, Jun 3, 2009 at 9:49 AM, Mary Nicole Hicks < [email protected]> wrote: > > I like Zf, but I would like to use only some parts of it. I would like to > use > ZF without having Zend_Registry, Zend_Locale and Zend_Config included into > PHP (eg through require_once). Can someone explain to me why ZF is so > reliant on Zend_Registry, Zend_Locale and Zend_Config? > > I have been following them and the first time that Zend_Registry and > Zend_Locale are used are: > > When I use Zend_Uri_Http::check($string) > Which Uses: Zend_Validate_Hostname > Which Uses: Zend_Validate_Abstract > Which Uses: Zend_Registry? > > I use Zend_Form_Element and in turn it: > Uses: Zend_Form_Decorator_HtmlTag > Which Requires: Zend_Filter_Alnum (to normalizeTag) > Which Requires: Zend_Locale? > > Why are these needed? > > Also in a some what related second question: > I have managed to remove all instances of Zend_Config from my code except > one. My reason for this is that a PHP array has much less overhead than > Zend_Config. In most cases in ZF I can use an array instead of Zend_Config. > > The only case I have found that I can not do this cleanly is to setup > Zend_Controller_Router_Rewrite. I am aware that I could add each route > manually from the php array, but why can't the "addConfig" of > Zend_Controller_Router_Rewrite also accept arrays like the constructor of > Zend_Db_Adapter_Abstract? > > (The constructor of Zend_Db_Adapter_Abstract converts a passed Zend_Config > instance into an array and works on the resulting array). > -- > View this message in context: > http://www.nabble.com/Do-I-have-to-use-Zend_Registry%2C-Zend_Locale-and-Zend_Config-if-I-use-ZF--tp23846280p23846280.html > Sent from the Zend Framework mailing list archive at Nabble.com. > > -- Vincent Gabriel. Lead Developer, Senior Support. Zend Certified Engineer. Zend Framework Certified Engineer. -- http://www.vadimg.co.il/
