[eluser]Dennis_gull[/eluser]
Is there a best practice for global objects in CI? I currently keep protected variables in MY_controller but I won't be able to access them in my model.
I know two ways to solve this, I can either use "global $user" or put the user in a singleton however I think using a singleton is a little overkill so if there is no other way to pass data to each model automatically I think I will go with the global alternative.
By the way, can't I extend model and pass over the user from the controller in some way?