Controller Suffix |
Is it really? I am not sure myself, but I would certainly bow to greater knowledge.
Here is an example. A customer emails: Quote:Found an error on www.somesite.com/reports where link doesn't work on custom report. I know immediately that it is the reports controller. I go there and see some function PHP Code: $this->reports_model->get link() and I know immediately that is a call to the reports model function get_link. I check in there and find the error. The alternative is: A customer emails: Quote:Found an error on www.somesite.com/reports where link doesn't work on custom report. I have to check the routes first for where that link is routed to. With hundreds of routes that might not be such a simple taks. I find the route and go there and see some function PHP Code: $this->reports->get link() Is it an internal function? I check the controller and it is not. Is it a library, I check the library and in the reports_library I find a get_link function. I cannot find an error with that and scratch my head for a while. Then I discover it is a model call, so I check the model and find another get_link function and there is the error finally. Personally I stick to the magic routes for CI! Admittedly the example above is completely fictitious. So in using a framework that provides a routing methodology, is it really best practice to define every route? Best wishes, Paul |
Messages In This Thread |
Controller Suffix - by ufhy - 08-05-2016, 08:56 AM
RE: Controller Suffix - by Avenirer - 08-07-2016, 10:31 PM
RE: Controller Suffix - by PaulD - 08-08-2016, 09:09 AM
RE: Controller Suffix - by ivantcholakov - 08-08-2016, 10:41 AM
RE: Controller Suffix - by Muzikant - 08-08-2016, 11:59 AM
RE: Controller Suffix - by PaulD - 08-08-2016, 01:56 PM
RE: Controller Suffix - by albertleao - 08-12-2016, 05:29 PM
RE: Controller Suffix - by marksman - 08-08-2016, 06:13 PM
RE: Controller Suffix - by PaulD - 08-12-2016, 05:57 PM
RE: Controller Suffix - by albertleao - 08-14-2016, 10:21 PM
RE: Controller Suffix - by PaulD - 08-15-2016, 03:00 AM
RE: Controller Suffix - by albertleao - 08-15-2016, 09:52 AM
RE: Controller Suffix - by spjonez - 08-15-2016, 07:41 AM
RE: Controller Suffix - by Ivo Miranda - 08-15-2016, 12:14 PM
RE: Controller Suffix - by albertleao - 08-15-2016, 02:12 PM
|