I just almost completed project in Codeigniter 4
and published it on hosting server. And now I am not able to access controller that is inside subdirectory.
For example: http://localhost/admin/auth/ - this URL works fine.
And when I access it on hosting server: http://x.someserver.com/admin/auth/
Then I am getting this error:
It's trying to load admin
controller which doesn't exist. Here is how my controllers are structured:
Note: Root.php
is my default controller.
I am not sure why this is happening. Or how can to resolve this. Here what I have found online similar issues.
One states that it needs to be namespaced.