CODEIGNITER 4 Post returns "error 404" |
I'm trying to use a post method in a form, but returns "error 404".
If anyone know what is happening please help me. Thanks HTML: PHP Code: <form action="<?= site_url('auth/save'); ?>" method="post" enctype="multipart/form-data" class="user"> PHP Code: public function save(){ ERROR: Can't find a route for 'auth/save'.
Since auto routing is disabled you need to write your routing line for your post processes as well:
PHP Code: $routes->post('YourController/your_method', 'YourController::your_method'); |
Welcome Guest, Not a member yet? Register Sign In |