Matthew,
I understand why things are being done and as a Software guy understand
when a major release comes out the issues invloved. At age 37 I guess
sometimes it gets disheartening when you cant make something work :) and you
were able to make it work before.
Please don't read into what I said as a bash against ZF just me dealing with
my Frustration. As I had just setup my Web Hosting servers to allow
Zend_Tool. I want to make sure I understand it before customers start
calling me :)
Thx guys I have some reading to do
Eric
Matthew Weier O'Phinney-3 wrote:
>
> -- Ehask71 <[email protected]> wrote
> (on Monday, 08 June 2009, 07:03 AM -0700):
>> Thx! But now I get errors "No Registry Entry for logger" I guess its
>> back
>> to the Docs to figure out how setting Registry stuff was changed.
>
> The bootstrap uses what is considered a "local" registry, versus a
> global static registry. As a result, you cannot use Zend_Registry's get,
> set, or isRegistered methods in order to locate items, as these operate
> on the global, static registry.
>
> As a convenience, the bootstrap exposes a "getResource()" method which
> can be used to pull resources from the local registry by name.
>
> The bootstrap gets registered with the front controller as a parameter,
> so you can always fetch a resource by pulling the bootstrap from the
> front controller. For example, to get your "logger" resource, try the
> following:
>
> $bootstrap =
> Zend_Controller_Front::getInstance()->getParam('bootstrap');
> $logger = $bootstrap->getResource('logger');
>
> // or, using method chaining:
> $logger = Zend_Controller_Front::getInstance()
> ->getParam('bootstrap')
> ->getResource('logger');
>
> Within your action controllers, front controller parameters may be
> pulled using the getInvokeArg() method; you can use this to get your
> bootstrap... and then your resource:
>
> $bootstrap = $this->getInvokeArg('bootstrap');
> $logger = $bootstrap->getResource('logger');
>
> // or, using method chaining:
> $logger = $this->getInvokeArg('bootstrap')
> ->getResource('logger');
>
> This is documented in the manual; see section 4.3.1.3, "Resource
> Registry", here:
>
>
> http://framework.zend.com/manual/en/zend.application.theory-of-operation.html#zend.application.theory-of-operation.bootstrap.registry
>
>> Man this can kill dev time especially when you quote x Hours on a
>> project then ZF jacks everything up from the way you thought it or
>> used to work.
>
> We've been trying hard to build out functionality incrementally. The
> addition of Zend_Application codifies some paradigms and best practices
> we've been working on, but it's clear that migration has been a bit
> difficult for some. If you have any thoughts on how to mitigate this in
> the future, I'd love to hear them!
>
>> There are no good examples out to show what a new Bootstrap should look
>> like
>> compared to an old one with Modules,Logger, etc. The Reference and Wiki
>> always leave me scratching my head LOL
>
> Well, we didn't actually have a formal bootstrap class previously, so
> I'm not entirely sure what you're referring to. Previously,
> bootstrapping was entirely procedural.
>
> --
> Matthew Weier O'Phinney
> Project Lead | [email protected]
> Zend Framework | http://framework.zend.com/
>
--
View this message in context:
http://www.nabble.com/Zend_Application_Bootstrap_Bootstrap--and-Zend_Log-tp23915940p23927214.html
Sent from the Zend Framework mailing list archive at Nabble.com.