Unable to access variable |
@ vitnibel thanks. Did not realize that. I thought initController was more or less working as a __constructor. Is there any way to add a __constructor to initController? I am creating my cache in the BaseController which is a bunch of settings for my website. They are mainly required in the view so that works ok but I create my CSS, JS, etc, in the __construct part of my Public_Controller and need to know the cache setting then. I would like to keep the reading of cache in the base controller and have it loaded it first. Any ideas?
I guess one solution is (1) insert below method into initController Code: public function loadGlobalSettings() Code: class Public_Controller extends BaseController{ Something like above is ok? |
Messages In This Thread |
Unable to access variable - by spreaderman - 03-26-2022, 08:49 PM
RE: Unable to access variable - by kenjis - 03-26-2022, 08:59 PM
RE: Unable to access variable - by iRedds - 03-26-2022, 09:04 PM
RE: Unable to access variable - by spreaderman - 03-26-2022, 09:37 PM
RE: Unable to access variable - by vitnibel - 03-27-2022, 12:45 AM
RE: Unable to access variable - by spreaderman - 03-27-2022, 01:14 AM
RE: Unable to access variable - by vitnibel - 03-27-2022, 03:01 AM
RE: Unable to access variable - by spreaderman - 03-27-2022, 05:06 AM
|