I believe the front controller has a reference to the bootstrap in its
params:
$bootstrap = Zend_Controller_Front::getInstance()->getParam('bootstrap');

--
Hector


On Wed, Jul 29, 2009 at 1:28 PM, B. Kamer <[email protected]> wrote:

> Hi,
>
> I am unsure if and how I can get an instance to a registered resource, if
> the context is not within an action controller.
>
> Inside an controller you can do something like :
>
> $bootstrap = $this->getInvokeArg('bootstrap');
> if ($bootstrap && $bootstrap->hasResource('log'))
>        $this->logger = $bootstrap->getResource('log');
> else
>        $this->logger = new Zend_Log();
>
>
> I need access to the logger from within an amf service:
> this->getInvokeArg('bootstrap') is not possible then?
>
> how do I get to the bootstrap instance
>
>
> Thanks
>
> Bas
>

Reply via email to