1

发布表单后,然后使用浏览器返回按钮返回页面,页面如何加载?

尤其是:

  • 页面的什么状态被缓存(初始或发布)?
  • 页面是否以相同的顺序重新加载脚本?
  • 什么表单发布数据被重新加载到页面字段中?
  • 在页面加载的什么时候重新填充表单发布数据字段?

有没有关于浏览器应该如何处理这个问题的标准文档?

4

2 回答 2

2

Unfortunately, the forward and back buttons are completely browser-dependent. For example, Internet Explorer will expire a page (and force reload) if the page's expiration header has passed, but Firefox will not. Firefox will retain what the user's form data, (cache the "posted" state of the page) but Internet Explorer will not.

于 2013-06-07T17:36:26.867 回答
1
  • 取决于浏览器
  • 从缓存或下载中加载,就像在其他时间加载页面一样
  • 输入是否保持填写取决于浏览器
  • 通常onload,但这取决于浏览器

前进/后退按钮不是 W3C 规范的一部分。您可能想要搜索“处理后退按钮”或类似内容。

于 2013-06-07T17:56:18.277 回答