Answer the question
In order to leave comments, you need to log in
Why might a TokenMismatchException be thrown other than no token?
During development, something was updated somewhere or something stopped, as a result of which the authorization form stopped working completely.
When I try to authorize, I get a TokenMismatchException, while the token is passed in the form.
<h2 class="text-center">Авторизация</h2>
<form method="POST" action="/login" accept-charset="UTF-8" role="form" class="form-horizontal">
<input name="_token" type="hidden" value="cwgcB2m9V9IKX9ZM3VMkNiWQVmPypB2evvOAIEwh">
<div class="form-group">
<label for="email" class="col-sm-2 control-label">Ваш E-Mail</label>
<div class="col-sm-8">
<input class="form-control" name="email" type="email" id="email">
</div>
</div>
<div class="form-group">
<label for="password" class="col-sm-2 control-label">Пароль</label>
<div class="col-sm-8">
<input class="form-control" name="password" type="password" value="" id="password">
</div>
</div>
<div class="form-group">
<div class="col-sm-8">
<label for="remember">Запомнить меня</label>
<input checked="checked" name="remember" type="checkbox">
</div>
</div>
<div class="form-group">
<div class="col-sm-2"> </div>
<div class="col-sm-8">
<button type="submit" class="btn btn-block btn-primary">Вход</button>
</div>
</div>
</form>
Answer the question
In order to leave comments, you need to log in
The value of the token does not match.
Use {{ csrf_field() }}
2nd option laravel.io/forum/01-30-2015-laravel5-tokenmismatch...
See your .env where sessions are stored.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question