Re: Best way to pass parameter to application
simplesi wrote: > > ... Just want to do it the "proper CakePHP" way :) > Having read more, I think the "proper" way is to read the parameter using $this->params['pass'][0] in the controller view function and use that to only select records for viewing for one particular school. regards Simon -- View this message in context: http://www.nabble.com/Best-way-to-pass-parameter-to-application-tp25043152p25076126.html Sent from the CakePHP mailing list archive at Nabble.com. --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Best way to pass parameter to application
Last year I learnt PHP and wrote a ICT helpdesk for some small schools that I'd like to redo using CakePHP. Previously each school used a url e.g http://www.school.com/helpdesk/?vsh_place=NameofSchool to pre-select their school in the database. I believe I should pass the school name using a url but I'm not sure whether/how to collect it in the controller and then pass it onto my add view (which is the view my users will use) or is it "OK" to directly collect it in my view e.g http://www.school.com/helpdesk/view/NameofSchool Just want to do it the "proper CakePHP" way :) regards Simon -- View this message in context: http://www.nabble.com/Best-way-to-pass-parameter-to-application-tp25043152p25043152.html Sent from the CakePHP mailing list archive at Nabble.com. --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---