try with
$db = $this->getInvokeArg('bootstrap')->getResource('db');
_____
De: Elvin Siriyev [mailto:[email protected]]
Enviado el: miércoles, 27 de mayo de 2009 10:48
Para: Dalibor Karlovic
CC: [email protected]
Asunto: Re: [fw-general] How to get an application resource inside a
controller action
i can access to db from Zend_Db_Table::getDefaultAdapter(), but for locale,
configurations, acl and etc. there must be fast access from controller and
view.
am i think right?
On Wed, May 27, 2009 at 10:10 AM, Dalibor Karlović <[email protected]>
wrote:
On Tuesday 26 May 2009 20:40:38 Vladas Diržys wrote:
> Hi,
>
> what is the right way to get a db (or any other) resource in the
> controller? Now I'm using following line:
> $this->getFrontController()->getParam('bootstrap')->getResource('db');
Why do you need you DB instance inside your controller?
--
Dado
--
Elvin Şiriyev
http://siriyev.net