General question: Seperate controller or a function??? |
[eluser]nelson.wells[/eluser]
I tend to break controllers down into logical structures that are easy to deal with. Controllers that hold a whole lot of functions like that can turn into a hairy mess really quick. You can put the work and education into their own controller and still have the url structure you are going for because controller + function does not = url. Look into the routing functions, I think they are fairly simple. For example, you could do something like (and this is without testing) $route["user_profile/(:any)/work"] = "work/index/$1"; What this would (hopefully) do is send a url http://www.domain.com/user_profile/jimmy05/work to the controller Work, the function index, and the parameter 'jimmy05' (a username). Hope that helps. |
Messages In This Thread |
General question: Seperate controller or a function??? - by El Forum - 02-15-2010, 04:41 PM
General question: Seperate controller or a function??? - by El Forum - 02-15-2010, 05:27 PM
General question: Seperate controller or a function??? - by El Forum - 02-15-2010, 09:47 PM
General question: Seperate controller or a function??? - by El Forum - 02-16-2010, 04:43 AM
General question: Seperate controller or a function??? - by El Forum - 02-16-2010, 06:36 AM
General question: Seperate controller or a function??? - by El Forum - 02-16-2010, 07:11 AM
|