2

我已经设置了一个搜索页面并且它工作正常,但是当我在浏览器中单击返回时,出现了问题(下面提到),那么我该如何禁用它。

Confirm Form Resubmission
This webpage requires data that you entered earlier in order to be properly displayed. You can send this data again, but by doing so you will repeat any action this page previously performed. Press Reload to resend that data and display this page.
4

2 回答 2

1

在您的页面上处理 POST 后

example.com/mypage.php

利用

header('Location: example.com/mypage.php');

这样,帖子将不会被重新提交,并且您不会从浏览器中收到警报。

于 2014-10-17T14:06:55.047 回答
-1

使用 Chrome 的命令行选项-disable-prompt-on-repost

于 2013-08-09T08:30:36.757 回答