If  I want set some parameter in the construct class, how can I do??

On Mar 9, 2:12 pm, Jeremy Burns | Class Outfit
<[email protected]> wrote:
> Try putting it in beforeFilter() instead (and don't forget to include 
> parent::beforeFilter() too).
>
> Jeremy Burns
> Class Outfit
>
> [email protected]http://www.classoutfit.com
>
> On 9 Mar 2011, at 13:02, Carachi wrote:
>
>
>
>
>
>
>
> > Hi,
> > I have this problem.
> > I want use a construct for a my controller so I insert in this
> > controller this function:
>
> > var $user;
> > public function constructClasses(){
> > $this->user = 'test';
> > }
>
> > but it return this error:
> > Fatal error: Call to undefined method stdClass::allow() in /home/www/
> > app/controllers/inizialization_controller.php on line 15
>
> > I also try in php way with __constructor() but doesn't works
>
> > Why??
> > Thank you
>
> > Bye
>
> > --
> > Our newest site for the community: CakePHP Video 
> > Tutorialshttp://tv.cakephp.org
> > Check out the new CakePHP Questions sitehttp://ask.cakephp.organd help 
> > others with their CakePHP related questions.
>
> > To unsubscribe from this group, send email to
> > [email protected] For more options, visit this group 
> > athttp://groups.google.com/group/cake-php

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
[email protected] For more options, visit this group at 
http://groups.google.com/group/cake-php

Reply via email to