Saturday, 23 April 2016

How to reload the page ?


Use a button click to reload the page but you can use a text hyperlink or any trigger you like.

Examples :
<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">

You can also use document object instead of window.

No comments:

Post a Comment

Note: only a member of this blog may post a comment.