"Reload method" This method forces the browser to refresh the current page
=================================================
the "One" requires a refreshed window with a name, such as ABC. On the page you want to close join
<body onunload= "Javascript:ABC.location.reload ()" >
"Two" if you want to refresh the parent window that will close the page, you can add the
<body onunload= "Javascript:window.opener.location.reload ()" >
"Three" refreshes the current, parent, topmost, specified time refresh object
Bind button Click event when page loads
$ (function () {
$ ("#按钮id"). Click (function () {
Refresh ();
});
});
Click the button to invoke the method
function Refresh () {
Window.location.reload ();//RefreshCurrentPage (forced refresh).
Parent.location.reload () Refreshes the Father object (forFrame)-need to be used within the IFRAME framework
Opener.location.reload () Refreshes the parent window object (forSingle OpenWindow
Top.location.reload () Refreshes the topmost object (formore openWindow
SetTimeout (' Refresh () ', 1000); //Specify 1 secondsRefresh Once
}
"Four" if you want to close the window when refreshing or when you want to open windows
<body onload= "Opener.location.reload ()" > Windows Refresh
<body onunload= "Opener.location.reload ()" > Refresh when off
<script language= "JavaScript" >
Window.opener.document.location.reload ()
</script>
"Five" auto refresh or Jump
1. Automatic page refresh: Add the following code to the
<meta http-equiv= "Refresh" content= ">"
20 refers to a refresh of the page every 20 seconds.
2. Page Auto-jump: Add the following code to the
<meta http-equiv= "Refresh" content= "20;url=http://www.baidu.com" >
Where 20 means jump to http://www.baidu.com page after 20 seconds
"Reload method" This method forces the browser to refresh the current page