By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
445,771 Members | 1,685 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 445,771 IT Pros & Developers. It's quick & easy.

Reloading a page programatically

P: n/a
Is there a way of reloading a page programatically - for example,

<script language="javascript>
document.location.reload()
</script>

BUT NOT HAVING TO MANUALLY CLICK A "RESET" BUTTOM.
Jul 20 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
In article <3F**************@theworld.com>, mg@theworld.com enlightened
us with...
Is there a way of reloading a page programatically - for example,

<script language="javascript>
document.location.reload()
</script>

BUT NOT HAVING TO MANUALLY CLICK A "RESET" BUTTOM.


That would do just that.

It would do it ad nauseum, though. :)

You could do it as part of a setTimeout if you wanted it reloaded, say,
every 5 minutes.

Here's mine. I use it with a frameset and this is the top frame, so it
has "self" in it.
<script type="text/javascript" language="javascript">
// settimeout for session expiration - check every 5 minutes
function reloadMe()
{
self.document.location.reload();
}
setTimeout("reloadMe()",1000*60*5);
</script>
-------------------------------------------------
~kaeli~
Jesus saves, Allah protects, and Cthulhu
thinks you'd make a nice sandwich.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace
-------------------------------------------------
Jul 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.