1

I am getting this error when I send requests over HTTP , it works correctly in HTTPS

this my form

<form id="login-form" action="{{ route('login') }}" method="POST">
     @csrf
    <div class="form-row-title">
        <h3>شماره موبایل</h3>
    </div>
    <div class="form-row with-icon form-group">
        <input type="text" name="username" class="input-ui pr-2" placeholder="  شماره موبایل خود را وارد نمایید">
        <i class="mdi mdi-account-circle-outline"></i>
    </div>
    <div class="form-row mt-3">
         <button type="submit" class="btn-primary-cm btn-with-icon mx-auto w-100">
         <i class="mdi mdi-login-variant"></i>
         ورود
          </button>
     </div>
    
</form>

when I dump csrf token in HTTPS request the CSRF token from the form field is the same as the csrf_token() function but in HTTP request they are different.

MMD
  • 35
  • 6
  • Can you please check this: https://stackoverflow.com/questions/52764590/laravel-419-error-verifycsrftoken-issue – Manoj Kumar Jan 01 '22 at 16:19
  • 1
    @ManojKumar Thanks you I found how to fix it from the Topic you sent :D the secure keyword inside session.php config file was set true i simply set it to false – MMD Jan 01 '22 at 17:24

0 Answers0