Using Cakephp, how to generate editable Pages?

Asked

Viewed 384 times

1

I’m developing a site using Cakephp, but although basic I would like to know the correct way to create pages like : Home, Contact, About, simple user page(logged in with permission 1), administrator page(logged in with permission 2), etc. For this I would like to have a.ctp template that would include views like header.ctp and footer.ctp or a view that lists a particular Bean for the simple user (no change options), another that lists the Bean for the administrator, among others. In addition these pages should have editable areas, only for the administrator, for future maintenance of a layman.

I thought of creating a Bean called editableareas that has all the editable fields of the site, the methods of Editableareascontrroler would have as view the pages of the site, but I do not know if it is possible to create methods with the name home, contact, etc.. and even if possible I don’t know if it would be good practice , because I don’t know if Pagescontrollers has this functionality.

I would also like to know, if possible, what to do in the following situation:

A site with 1°tamplate including view and certain parts 2°a Home which shows public menu with (Home,Contact,Services), in this home would have an editable div talking about the company(this div would be written by the user). Fully editable contact. 3°and Services that would display a list of the Bean service, but in a different way than is shown to the administrator (no options to delete and edit )

  • 2

    I recommend you see this tip on Cakephp Forum from there evolve your doubts as you go developing your application, tune up accounts here we will ask your questions and we will not make design for you

  • I guess I didn’t know how to express myself, just wanted recommendations from some previous patterns not to do "gambiarra", but decide to make a Model Editablecontent that has its name and its value, each page inserts the content by name

  • 1

    Everything you have commented on can be done and can be seen on Documentation of Cakephp

  • Start with the tutorial on how to build your first blog, it’s already a big step Tutorials & Examples Study about POO, because without this basis, it becomes difficult to implement all the resources of the Cakephp

1 answer

1

You can use the CMS Croogo for that reason.

You can use all of Cakephp’s permission features, such as ACL, you can use Croogo’s page and blog resources, and you can make your own Cakephp code normally without any incompatibility.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.