CodeIgniter Forums
Ion-auth 4 routes not working - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28)
+--- Forum: CodeIgniter 4 Addins (https://forum.codeigniter.com/forumdisplay.php?fid=34)
+--- Thread: Ion-auth 4 routes not working (/showthread.php?tid=73118)



Ion-auth 4 routes not working - akjackson1 - 03-20-2019

I used the manual installation method of CI4, and did the same for the updated version of Ion-Auth designed to work with CI4. After copying over the files into my CI4 installation I discovered that it is not routing correctly. When navigating to /auth/login, I get the error message "Controller or its method is not found: App\Controllers\Auth::login". 

I suspect I've not done something correctly related to namespacing, since if I change:

namespace IonAuth\Controllers;
class Auth extends \CodeIgniter\Controller

To

namespace App\Controllers;
use CodeIgniter\Controller;
class Auth extends Controller

It works routes correctly, but I then get the error: "Class 'IonAuth\Libraries\IonAuth' not found".

What am I doing wrong here?


RE: Ion-auth 4 routes not working - donpwinston - 03-20-2019

"...and did the same for the updated version of Ion-Auth designed to work with CI4..."

Where did you get this?


RE: Ion-auth 4 routes not working - snelledre - 03-20-2019

I know I work because I have played with it last year and it works.
Did you place the Ion-Auth directory in the root, so beside the public and the application directory?

Follow this guide and I know it works.

Succes

Andre