用JavaScript检测PHP形式的XHR进度
我在提交上提交此表格上有一个带有Action PHP的表格,
<form method="POST" action="action.php">
<input type="text" name="name" />
<input type="submit" value="submit" />
</form>
将加载执行请求时的页面;
我想要的是JavaScript,以检测请求的进度,以向用户显示其提交表格为n%;因为如果我的PHP有很大的待遇,则用户将不知道他的形式的进度在哪里;如果使用AJAX,我们可以捕获请求的进度,但是只有PHP表格的情况,我不知道如何捕捉进度
I have a form with action php on submit
<form method="POST" action="action.php">
<input type="text" name="name" />
<input type="submit" value="submit" />
</form>
this form on submit will load the page on executing the request;
What i want is with javascript, to detect the progress of the request to show user that his submit form is at N %; cause if i have a big treatment in my php, the user will not know where is the progress of his form; if using ajax we can catch the progress of request but with the case of only php form, i have no idea on how to catch the progress
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论