We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I set the set404Override in group rotes, But it does not work and gives an error.
$routes->group('panel', ['filter' => 'role:Writer'], function($routes) { $routes->setDefaultNamespace('App\Controllers\Panel'); $routes->set404Override('Show404::index'); $routes->get('home', 'Home::index'); $routes->get('posts', 'Post::index'); // And more... });
But when I set it like this it works right:
$routes->set404Override('App\Controllers\Panel\Show404::index');
Is this a bug? or am i wrong?
I using this platform: CodeIgniter 4 version
The text was updated successfully, but these errors were encountered:
https://codeigniter.com/user_guide/incoming/routing.html#override In the current version, the method expects the full path to the 404 error handling class. Also, only one 404 error handler can be defined.
This is not a bug, but normal behavior.
Also, in your case, it would be more correct to specify the namespace through an array
$routes->group('panel', ['filter' => 'role:Writer', 'namespace' => 'App\Controllers\Panel'], function($routes) { //... });
Sorry, something went wrong.
Thanks @iRedds for the explanation. Closing this.
No branches or pull requests
I set the set404Override in group rotes, But it does not work and gives an error.
But when I set it like this it works right:
Is this a bug? or am i wrong?
I using this platform:
CodeIgniter 4 version
The text was updated successfully, but these errors were encountered: