0

Is it possible to access controller from action helper?

class Zend_Controller_Action_Helper_UserLimit extends Zend_Controller_Action_Helper_Abstract
{
    public test()
    {
        $this->getController(); // get controller which initiated the helper
    }
}

1 Answer 1

1

Yes, it is possible:

$controller = $this->getActionController();

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.