Zend Controller Action Helper Problem not able to add helper

Posted by snakeyyy on Stack Overflow See other posts from Stack Overflow or by snakeyyy
Published on 2011-01-02T21:51:49Z Indexed on 2011/01/02 21:53 UTC
Read the original article Hit count: 274

Filed under:
|

Trying to make a controller helper to have similar functionality in some controllers using the preDispatch method.

Error:

Fatal error: Class 'Helper_Action_Test' not found in /var/www/zend.dev/application/Bootstrap.php on line 9`

Application layout

/Application
 /Helpers
   **/Actions** this is where i will save the classes
   /Views
 /modules
 /configs
 /layouts
 /Bootstrap.php

In the Bootstrap I have added:

protected function _initActionHelpers(){
  Zend_Controller_Action_HelperBroker::addHelper(new Helper_Action_Test());
}

In the helper file I have:

class Helper_Action_Test extends Zend_Controller_Action_Helper_Abstract{

    public function  preDispatch() {
       echo 'Test';
    }

}

Any ideas?

© Stack Overflow or respective owner

Related posts about zend-framework

Related posts about zend