Laravel 5.7 error 404 handling page location
actually you can override it in app/Exceptions/Handler.php
and set the code look like this.
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
class Handler extends ExceptionHandler
{
if ($this->isHttpException($exception)) {
if ($exception instanceof NotFoundHttpException) {
return response()->view('error_404_path', [], 404);
// abort(404);
}
return $this->renderHttpException($exception);
}
}
You can find it here:
vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/views/404.blade.php
You shouldn't be editing this file directly though. If you want to add your custom error page just add an errors folder inside the resources/views and create your own 404.blade.php as desired. It will be used instead of Laravel's one.