Hi KN,

I would say: Always send the info TO the view :).

It's only one possible solution, but you could create a component to
get any data you are wanting, include the component in your app
controller. in the layout render your TotalSales element and in this
way all of your pages would have the total sales included on the page.

A similar example:
http://wiki.cakephp.org/tutorials:blog_tutorial_-_2#adding_a_recent_post_element_to_another_page

If you want the component to receive parameters from the controller, an
alternative approach would be to call the component explicitly passing
the parameters, rather than doing it in the startup method. See how the
pagination component is used in this example:
http://wiki.cakephp.org/tutorials:pagination

HTH, Cheers,

AD7six


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

Reply via email to