Home > Web Front-end > JS Tutorial > body text

How to handle exceptions displayed when post submits data

一个新手
Release: 2017-10-01 07:45:28
Original
3299 people have browsed it


When post submits data, it displays as follows:

The page has expired due to inactivity. 
Please refresh and try again
Copy after login

This is due to this requirement in the laravel framework: any HTML form that points to the POST, PUT or DELETE route in the web Requests should all contain a CSRF token, otherwise, the request will be rejected.

eg:

<form method="POST" action="/profile">
{{ csrf_field() }}    ...</form>
Copy after login

The above is the detailed content of How to handle exceptions displayed when post submits data. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!