i am writing an action helper and i need to call another action helper from within that helper. but i dont know how. here in the sample code:
class Common_Controller_Action_Helper_SAMPLE extends Zend_Controller_Action_Helper_Abstract { protected $_view; public function __construct(Zend_View_Interface $view = null, array $options = array()) { $this->_view = $view; } public function preDispatch() { $flashMessenger = $this->_helper->FlashMessenger; // IT IS NULL } }
Use the action helper broker:
$flashMessenger = Zend_Controller_Action_HelperBroker::getStaticHelper('FlashMessenger');
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With