Javascript refresh (Javascript)

by spyka (http://www.spyka.net)

Use the below snippet to create a button to refresh the current page. Change the argument from false to true to get the webpage from the web server, this is useful if you have dynamic content.

Code:
<input type="button" value="Refresh" onClick="window.location.reload(false)" />

Code demo

Javascript refresh online demo

Help and comments

Discuss this and other scripts in our webmaster foruns

Learn more about our forums