The users of my Website told me that they got the tokenmismatchexception when the sent the formular.
If I try I didn't got it.
So, in which cases does the tokenmismatchexception come? How can I catch it?
Thank you in advanced.
The users of my Website told me that they got the tokenmismatchexception when the sent the formular.
If I try I didn't got it.
So, in which cases does the tokenmismatchexception come? How can I catch it?
Thank you in advanced.
This error appears when:
The user leaves the page opened for a long time of period, The default time is 2 hours
and can be configured in config/session
- lifetime
When you submit a form without including the _token
field or without excluding the url on app/Http/Middleware/VerifyCsrfToken
To put the _token
field on any form you can use {!! csrf_field() !!}
You can check the docs for more information