Quite often I need to display data that's common to a lot of views -
for example, when dealing with a user that's linked to an organisation,
to display the organisation that the user belongs to on every page they
see. It seems obtuse to have to call $this->User->Find... in every
function in every controller. Outside Cake, I'd usually stick the
organisation in the session to save lookups and provide easy access,
but I've not found a way of accessing a session value from a view
without having to call set() in every function, which is almost as bad.
I suspect there is some simple 'Cakeish' way of sharing data between
views, and across different controllers, but I've not found it as yet.


--~--~---------~--~----~------------~-------~--~----~
 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