Can you provide the error you were getting when defining inner helpers in the 
$helpers array?


Cheers,

Graham Weldon
e. [email protected]
p. +61 407 017 293
w. http://grahamweldon.com



On 13/01/2010, at 8:41 AM, Deine Mutter wrote:

> Hey,
> 
> I'm creating my own helper (PagescrollHelper). I need to include the
> HtmlHelper and the FormHelper into it. As described in the doc (http://
> book.cakephp.org/view/102/Including-other-Helpers) I used:
> 
> var $helpers = array('Html');
> 
> This however leads to an error, which is even described in the
> comments of therespective doc section. So I tried the suggested
> alternative (google tells me the same) which goes like this:
> 
>        App::import('Helper', 'Html');
>        $Html = new HtmlHelper();
> 
> This works fine for the HtmlHelper. But if I add the FormHelper in the
> same manor,
> 
>        App::import('Helper', 'Form');
>        $Form = new FormHelper();
> 
> calling e.g. $Form->input results in the following error:
> 
> Undefined property: FormHelper::$Html [CORE/cake/libs/view/helpers/
> form.php, line 963]
> Trying to get property of non-object [CORE/cake/libs/view/helpers/
> form.php, line 963]
> 
> 
> 
> I figure that what I'm trying to do should be something quite casual,
> so there should probably be a solution or a huge mistake in my
> attempt. Could anyone help?
> 
> Thanks
> Check out the new CakePHP Questions site http://cakeqs.org and help others 
> with their CakePHP related questions.
> 
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected] For more options, visit this group at 
> http://groups.google.com/group/cake-php?hl=en


Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

Reply via email to