Force browser to reload or refresh
How do I force a reload/refresh from the current page? Found at http://www.irt.org
AI
Ringkasan AI: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.
Kode Sumber
You can for JavaScript 1.1 use the location objects reload method: <FORM> <INPUT TYPE="BUTTON" onClick="window.location.href.reload()" VALUE="Reload"> </FORM> Failing that you could try a meta tag that doesn't allow the page to be cached so that the following would reload: <FORM> <INPUT TYPE="BUTTOM" onClick="window.location.href=window.location.href"> </FORM> The no cache meta tag needs to be placed in between the <HEAD> and </HEAD> tags: <META HTTP-EQUIV="no-cache"> Or you could use the meta tag for expires, to always ensure that a newer copy is loaded: <META HTTP-EQUIV="expires" CONTENT="Wed, 26 Feb 1997 08:21:57 GMT"> Or you could refresh the page automatically after a delay using the refresh meta: <META HTTP-EQUIV="Refresh" CONTENT="3;URL=http://www.some.org/some.html"> Upload Upload
Komentar Asli (3)
Dipulihkan dari Wayback Machine