How to use JavaScript Location reload

In this article I have described about Dom Node Location reload() method in JavaScript.
  • 2026

JavaScript Location reload() method

  • As we know that location object contains information about the current URL.
  • The location object has a method named reload() method that reload current document.

Browser support

Following are the main browsers which support the reload() method of location object

  • Internet Explorer.
  • Firefox.
  • Opera.
  • Google Chrome.
  • Safari.


The reload() method of location object has following syntax


Lets take an example

<!DOCTYPE html>



<script type="text/javascript">

    function reloadPage()






<body style ="background-color:yellow">

<input type="button" value="Reload page" onclick="reloadPage()" />





When we click on button it reload the current document

Further Readings

You may also want to read these related articles :here

Ask Your Question 

Got a programming related question? You may want to post your question here

Programming Answers here


More Articles

© 2018 DotNetHeaven. All rights reserved.