I have a custom helper (MessageHelper
) in which I need access to another custom helper (IncentiveHelper
). I've followed the format described in the docs, but I'm getting this error:
Undefined property: MessageHelper::$Incentive [APP/views/helpers/message.php, line 21]
Here's the relevant chunk of code. To my eye, it looks virtually identical to that in the 1.3 docs:
class MessageHelper extends AppHelper {
public $helpers = array( 'Incentive' );
public function rebates( $rebates ) {
debug( $this->Incentive ); exit;
}
}
The files are named and stored according to convention as app/views/helpers/message.php
and app/views/helpers/incentive.php
. On a whim, I did try including a core helper (HtmlHelper
) instead, but that failed the same way.
What am I missing here? Is there something obvious that I'm just not seeing? Seems like there must be, but my eyes are starting to cross. Any nudge in the right direction would be much appreciated.