Auto Refresh Page in JavaScript

JavaScript Code to Refresh page in Fixed Interval

In many cases we need to Create a JavaScript function to refresh webpage in periodic intervals for applications like market status, weather reports and some applications which changes time to time we need to reload a page or particular area in a webpage. Here there are two examples for refreshing webpage with fixed time interval.
//Example 1 calling JavaScript in onload()

<script type="text/javascript">
function refreshpage(){
setTimeout("refresh()", 2000);
function refresh(){
<body onload="refreshpage()">

//Example 2 calling by default

var timer;
function refreshmypage(){

Related Topic List of Common Mistakes Designing Website
How to Reload IFrame using Javascript
Refresh Page Using Javascript Example
Create Slideshow jQuery
Dynamic jQuery Loading on Page Scroll 2011   Privacy Policy  Terms of Service  Feedback