2009-08-18

java Reload the Page With JavaScript

How to Reload the Page With JavaScript
There are several ways to reload the current page using a button or
other trigger. The examples below use a button click to reload the
page but you can use a text hyperlink or any trigger you like.

<input type="button" value="Reload Page" onClick="window.location.reload()">

<input type="button" value="Reload Page" onClick="history.go(0)">

<input type="button" value="Reload Page"
onClick="window.location.href=window.location.href">

0 留言: