peterhf wrote:
> I have created a thtml file and placed it in the /pages/ directory. In
> the file I have "if ($this->Session->check('function')) ...". The
> following error message appears: "Fatal error: Call to a member
> function on a non-object in ..." which points to the line containing
> the "...Session->check....".
> 
> I thought that the Session Component was available to every Cake
> controller including the PagesController.
> 
> Where have I gone wrong?

In the view it's better to interact with the SessionHelper than with the
SessionComponent. So $session->check('function') should solve your
little problem.

M.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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