Hi,
I use a custom view class that inherits from the Zend_View. I haven't had any
problems with calling helpers using $this->Helper(); Maybe looking at the
Zend_View __call() would help?
In my helpers I use:
Public $view;
/**
* Internal used by zend_view, to send
* a reference of the view to the helper.
*
* @param view $view
*/
public function setView( $view )
{
$this->view = $view;
}
Zend_View then sets a reference to view in the helper so I can access the view
class variables.
Not sure if this is what you mean but I hope it helps :)
Keith Pope
Web Developer
-----Original Message-----
From: Dan Rossi [mailto:[EMAIL PROTECTED]
Sent: 07 August 2007 14:31
To: [email protected]
Subject: Re: [fw-general] View helper problem
Thanks matt sorry about that. Ive implemented a custom View class for rendering
pear's html_template_flexy templates as its more designer friendly. Im having
an issue there where its compiling its templates with method_exists so call
doesnt get run. When i try $this->method $this is calling the template class ,
it seems $t is compiled as the view pointer so $t->method() works.
My problem with these helper classes now though is, i needed these methods to
output things like a custom image or button image. But these are reliant on
some session variables, so i guess i have to get the session from the
$this->view class which i set it from a registry correct ?
Matthew Weier O'Phinney wrote:
> -- Dan Rossi <[EMAIL PROTECTED]> wrote (on Tuesday, 07 August
> 2007, 11:06 PM +1000):
>
>> Hi ive gone through all the documentation to create a view helper, so
>> i can call some methods in the view scripts however call never gets
>> run , im still getting this "Call to undefined method"
>>
>
> Hard to diagnose without the following:
>
> * the view helper
> * a view script where you attempt to call the view helper
>
> Please provide these, and I'll see if I can diagnose the issue.
>
>
--
allpay.net Limited, Fortis et Fides, Whitestone Business Park, Whitestone,
Hereford, HR1 3SE.
Registered in England No. 02933191. UK VAT Reg. No. 666 9148 88.
Telephone: 0870 243 3434, Fax: 0870 243 6041.
Website: www.allpay.net
Email: [EMAIL PROTECTED]
This email, and any files transmitted with it, is confidential and intended
solely for the use of the individual or entity to whom it is addressed. If you
have received this email in error please notify the allpay.net Information
Security Manager at the number above.