Re: A Web-app for small business
Thank you! This works great for the first, and there are a few question on the implementation. For the first I want to change the active state by the parameters that are passed through my pages/display function but I don´t know where I must change the code. For the second I´m asking where I can find the values that are defined in the function beforeFilter and what effect they have. I do not understand what the function beforeFilter exactly does or where the data is stored in my views or layout, because in debug($this) is no variable menus either I can not debug $menus within my views or layout. So do I have not understood the concept, have´t I? Thanks On 30 Nov., 17:20, jburns jeremybu...@me.com wrote: I wrote an article on this just last week; this might help: http://www.jeremy-burns.co.uk/2009/11/cakephp-dynamic-navigation-bars/ On Nov 30, 3:53 pm, davido mail.dk.onl...@gmail.com wrote: Hello, I´ll try to make a web app for asmallbusinessowners web presence. I found cakephp as the right tool for fast development. Now I have wrote my model and controller classes and the views. In the layout I would like to switch the visability of the menu by a simple Callback function. Am I right using the beforeFilter for passing active state to the view as in the example I found on,http://old.nabble.com/beforeFilter-on-app_controller-and-on-posts_con..., google? Ex: app_controller before filter: function beforeFilter() { $this-set('SiteRoot', '/bla/'); //default menu to nothing $this-set('MenuSelected', '0'); } post_controller before filter function beforeFilter() { parent::beforeFilter(); $this-set('MenuSelected', '1'); } Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions. You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
A Web-app for small business
Hello, I´ll try to make a web app for a small business owners web presence. I found cakephp as the right tool for fast development. Now I have wrote my model and controller classes and the views. In the layout I would like to switch the visability of the menu by a simple Callback function. Am I right using the beforeFilter for passing active state to the view as in the example I found on, http://old.nabble.com/beforeFilter-on-app_controller-and-on-posts_controller--td16543705.html, google? Ex: app_controller before filter: function beforeFilter() { $this-set('SiteRoot', '/bla/'); //default menu to nothing $this-set('MenuSelected', '0'); } post_controller before filter function beforeFilter() { parent::beforeFilter(); $this-set('MenuSelected', '1'); } Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions. You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
Re: A Web-app for small business
I wrote an article on this just last week; this might help: http://www.jeremy-burns.co.uk/2009/11/cakephp-dynamic-navigation-bars/ On Nov 30, 3:53 pm, davido mail.dk.onl...@gmail.com wrote: Hello, I´ll try to make a web app for a small business owners web presence. I found cakephp as the right tool for fast development. Now I have wrote my model and controller classes and the views. In the layout I would like to switch the visability of the menu by a simple Callback function. Am I right using the beforeFilter for passing active state to the view as in the example I found on,http://old.nabble.com/beforeFilter-on-app_controller-and-on-posts_con..., google? Ex: app_controller before filter: function beforeFilter() { $this-set('SiteRoot', '/bla/'); //default menu to nothing $this-set('MenuSelected', '0'); } post_controller before filter function beforeFilter() { parent::beforeFilter(); $this-set('MenuSelected', '1'); } Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions. You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en