Welcome Guest, Not a member yet? Register   Sign In
Managing psr4 autoload inside a Controller
#1

Hello, I'm trying to load psr4 data in a certain Controller, but this doesn't work:

PHP Code:
$psr4 = ['Something' => APPPATH.'Something'];

$loader = new \CodeIgniter\Autoloader\Autoloader($psr4);
$loader->register(); 

Is there anyway I can make it work? I know I can put the new values in the Autoload config file, but I don't want to do that. Any tips?

Thank you.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB