Or also like this
$bootstrap = $this->getInvokeArg('bootstrap');
$resource = $bootstrap->getResource('myResource');
Sergio Rinaudo
Date: Thu, 7 May 2009 17:23:42 +0200
From: [email protected]
To: [email protected]
Subject: Re: [fw-general] Get Resources (DB) from Controllers
Sorry, i make a mistake, i forget the "t" in "bootstrap" :
$this->getFrontController()->getParam('bootstrap')->getResource('HereTheResourceYouNeed')
Pierrick Boulière a écrit :
In your
controller (or controller action), you can get the resource you need by
:
$this->getFrontController()->getParam('boostrap')->getResource('HereTheResourceYouNeed')
example :
$this->getFrontController()->getParam('boostrap')->getResource('db')
iceangel89 a écrit :
how can i access resources like the default
db adapter from my controllers?
_________________________________________________________________
Cerca le Parole, gioca su Typectionary!
http://typectionary.it.msn.com/