From app/Exceptions/Handler.php you can return an http response from render
public function render($request, Exception $e)
{
// translates 404's 500's into views found in resources/views/errors
if ($this->isHttpException($e)){
return $this->renderHttpException($e);
}
//if debug mode show some details about the exception that was thrown
if(config('app.debug')){
return (new SymfonyDisplayer(true))->createResponse($e);
}
//Gen pop gets a static view when their request breaks our site
return \Response::view('errors.exception');
}
and of course just make that view in resources
Also if you set APP_DEBUG=true in .env then you can see all the error info in the browser
Edit: I went ahead and fixed my own response when i figured this out, code edited to show what I came up with.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community