• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Load custom config file?

#1
I made a custom config file with some general settings I want to access in my controllers.

When I make a new controller and load the config file I can access the variables I set:

Code:
$customvalues = new \Config\Custom();
echo $customvalues->myvalue;

How can I load the config file so that I dont have to initiate a new instance in every class of the controller but like in codeigniter 3 one would do in a constructor function?
Reply


Messages In This Thread
Load custom config file? - by vinyl - 04-11-2020, 05:51 AM
RE: Load custom config file? - by includebeer - 04-12-2020, 07:23 AM
RE: Load custom config file? - by InsiteFX - 04-12-2020, 02:34 PM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme ¬© 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.