Welcome Guest, Not a member yet? Register   Sign In
Unable to locate the specified class: Session.php
#15

(11-12-2014, 02:26 AM)sv3tli0 Wrote: Pre-hooking controller construction means that you don't have anything loaded inside the controller object so the last suggestion of ciadmin will help you.

BTW instead of prehooking controllers I can suggest another tactic using MY_Controller which will be used from your controllers and will extend CI_Controller..
There you will have real control of the ci controller construct + you can add any custom common method for all controllers.

It is hard to help the Original Poster, as there is no mention as to what the goal of the pre-hook is.

I have only found one use for the hooks in my projects.

I tend to use the My_Controller approach, which gives me all I need, as you can hook into the __construct and the __destruct to take care of what you need to at the start and then end of a run.

I can see a use for the hook if you have some analytics and have the page cache system running.
Reply


Messages In This Thread
RE: Unable to locate the specified class: Session.php - by Chroma - 11-14-2014, 07:50 AM



Theme © iAndrew 2016 - Forum software by © MyBB