I’ve just started with CakePHP and am having a problem withe the concept of plugins and components.
The main issue is how to include their views in my own app. For example, on the cakephp site, there is a tutorial for plugins, but they never mention how to include it in the output of my own app.
I want to create a login bar that appears on every page of my site. You know, something that either says Username Password or Welcome Fred Flintstone at the top of every page.
It seems a plug-in would be best for this as it could be included in every controller I created. But, as I mentioned, I have no idea how to include the plugin view with my app views.
lee
In this case, you would create an element:
/app/View/Elements/login_bar.ctp
and include it in your views (or layout) with:
See: http://book.cakephp.org/2.0/en/views.html#elements