Refresh Browser?

liunx

Guest
is there an easy way, or any way at all, to make a browser refresh its page (including images) from the server in HTML/javascript or whatever?<br />
<br />
Thanks<!--content-->Hi!<br />
<br />
Example: <a href=http://www.webdeveloper.com/forum/archive/index.php/"#" onclick="location.reload();return false">click</a><br />
<br />
In modern browsers, it will work as well with an image or another type of tag instead of href.<br />
<br />
Cheers - Pit<!--content-->Yanhead<br />
<br />
If you want to be sure the visitor always gets the latest update of your page you can include this META tag:<br />
<br />
<META HTTP-EQUIV="refresh" content="1;URL=http://www.yoursite.com/newpage.htm"> <br />
<br />
The digit within the code defines how long the browser is to wait before performing a refresh of screen content.<!--content-->Originally posted by philaweb <br />
Yanhead<br />
<br />
If you want to be sure the visitor always gets the latest update of your page you can include this META tag:<br />
<br />
<META HTTP-EQUIV="refresh" content="1;URL=http://www.yoursite.com/newpage.htm"> <br />
<br />
The digit within the code defines how long the browser is to wait before performing a refresh of screen content. <br />
<br />
thanks, do you know if it'll definetly refresh from the server and not the cache? or can't this be guaranteed?<br />
<br />
Sometimes the HTML page can be updated but the images are taken from the cache.<!--content-->Originally posted by Yanhead <br />
do you know if it'll definetly refresh from the server and not the cache? or can't this be guaranteed?<br />
<br />
Googled this (<!-- m --><a class="postlink" href="http://wp.netscape.com/assist/net_sites/pushpull.html">http://wp.netscape.com/assist/net_sites/pushpull.html</a><!-- m -->) answer to your question.<br />
<br />
Seems like the META refresh works the same way as clicking the browser refresh button, which according to my knowledge always refreshes from server.<!--content-->Yanhead,<br />
<br />
According to w3 [ link (<!-- m --><a class="postlink" href="http://www.w3.org/TR/1999/REC-html401-19991224/struct/global.html#edef-META">http://www.w3.org/TR/1999/REC-html401-1 ... #edef-META</a><!-- m -->) ] ...Some user agents support the use of META to refresh the current page after a specified number of seconds...<br />
<br />
So, probably not all browsers (user agents) can be guaranteed to do this.<!--content-->Originally posted by philaweb <br />
Yanhead,<br />
<br />
According to w3 [ link (<!-- m --><a class="postlink" href="http://www.w3.org/TR/1999/REC-html401-19991224/struct/global.html#edef-META">http://www.w3.org/TR/1999/REC-html401-1 ... #edef-META</a><!-- m -->) ] ...Some user agents support the use of META to refresh the current page after a specified number of seconds...<br />
<br />
So, probably not all browsers (user agents) can be guaranteed to do this. that would be correct, meta refresh is the same as a meta redirect, notice on the forums it provides a backup link if you do not support it? You can do a refresh server side with an http header.<!--content-->thanks, do you know if it'll definetly refresh from the server and not the cache? or can't this be guaranteed?<br />
Nothing can really be guaranteed with all the browsers out there but if you put the full compliment of "no cache" http-equiv tags in your head section you'll get full reloads in most of the mainstream ones.<!--content-->...if you put the full compliment of "no cache" http-equiv tags in your head section you'll get full reloads in most of the mainstream ones. [/B] <br />
<br />
Do you know where I can find the 'full compliment' of Tags?<br />
<br />
:confused: <br />
<br />
Thanks<!--content-->Originally posted by Yanhead <br />
Do you know where I can find the 'full compliment' of Tags?<br />
<br />
:confused: <br />
<br />
Thanks he means meta tags.<br />
<br />
<meta http-equiv="Pragma" content="no-cache"/><br />
<meta http-equiv="Expires" content="Mon, 01 Jan 1990 12:00:00 GMT"/><br />
<meta http-equiv="Cache-control" content="no-cache"/><br />
<meta http-equiv="Cache-control" content="must-revalidate"/><br />
<meta http-equiv="Cache-control" content="max-age=0"/><br />
<br />
that should do it I think.<!--content-->that should do it I think. <br />
<br />
Superb,<br />
<br />
Thanks.<!--content-->
 
Back
Top