Level 73
You can handle that manually, in your Exceptions\Handler.php class add this in the render method:
if ($exception instanceof TokenMismatchException) {
return redirect('login')->with('message', 'An error message.');
}
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
hi, maybe it's repeated question,
if I logout after the session expire I got 419 | Page Expired so how to redirect to the login page either as auto redirect or when i post the logout after session expire ,?
thanks,
Please or to participate in this conversation.