Apr 18, 2024
0
Level 1
Token expired issue when submit form gets wired.
Encountering a wired issue! When requesting a page for the first time, the session token isn't stored, leading to a token expiration issue when submitting a form. However, from the second time onward, it gets stored.
While debugging the Laravel default ValidateCsrfToken middleware, it shows that initially, the session isn't stored, and it keeps generating a new token. However, after refreshing the page, the session gets stored. Do you have any idea why this is occurring?
This issue is also very frustrating for AJAX requests
Please or to participate in this conversation.