Here's how I break it down:

1) Anything thats on *every* page goes in the layout

2) Anything thats repeated on more than one page but not on all, goes
in an element (and imported into the view with echo $this->element
("foo"))

3) Anything that's unique to a page goes in the view.

So, as an example. Take a blog article page with a header, footer,
article and a sidebar with a tag cloud that displayed on the index &
view pages:

1) Header & footer goes in the layout

2) Tag cloud goes in an element and is imported in the index and view
views.

3) The article itself goes in the view.

Hope this helps :-)


On Jan 18, 3:06 pm, Bankai <[email protected]> wrote:
> So, I have all the html laid out.
>
> I want to make it so that I don't have to copy and paste  all the html
> every time I create a new page or change the layout in each and every
> page every time I make a change in the html code.
>
> I used to do that in the past with just plain PHP, but I want to make
> it using cakephp.
>
> I am having a hard time doing it with cakephp.
>
> Could somebody guide me in right direction? maybe some tutorial
> anywhere? I tried some Dynamic Content tutorials but it doesn't work.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" 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