Hi Ralph,

now it complains about:

Fatal error: Call to protected method Zend_Controller_Action::_forward()
from context 'Quasda_User_Helpers_UserHelper'
in /www/quasda/library/Quasda/User/Helpers/UserHelper.php on line 8

/Ralf

Am Sonntag, den 21.10.2007, 21:38 -0500 schrieb Ralph Schindler:
> Ralf Kramer wrote:
> 
> > 
> > public function init()
> > {
> > Zend_Controller_Action_HelperBroker::addPrefix('Quasda_User_Helpers');
> > $helper = Zend_Controller_Action_HelperBroker::getHelper("User_Helper");
> > $helper->doSmth();
> > }
> > 
> 
> 
> Try this:
> 
> public function init()
> {
>    Zend_Controller_Action_HelperBroker::addPrefix('Quasda_User_Helpers');
>    $helper = $this->_helper->getHelper('User_Helper');
>    $helper->doSmth();
> }
> 
> Reason being is that you want to use the helper broker that is specific 
> to the current ActionController.  That way, the helper you are trying to 
> use will have an instance of the ActionController itself.
> 
> -ralph

Reply via email to