a webmaster learning community
     Home    Register     Search      Help      Login    
FrontPage Alternative
Sponsors

Hosting from $3.99 per month!

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions. dd

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

 

Refresh page onload ONCE ONLY

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> General Web Development >> Refresh page onload ONCE ONLY
Page: [1]
 
RickP

 

Posts: 693
Joined: 11/13/2004
From: Kent, U.K.
Status: offline

 
Refresh page onload ONCE ONLY - 12/5/2004 8:53:04   
My question is so simple but I am struggling to find an answer that works - including having searched previous threads in this forum!

How does one cause a page to be refreshed ONCE ONLY when it is loaded into the visitor's browser?

HTML? SCRIPT? WHATEVER? Any offers of a solution that works?

Thanks, Rick
Kitka

 

Posts: 2520
Joined: 1/31/2002
From: Australia
Status: offline

 
RE: Refresh page onload ONCE ONLY - 12/5/2004 12:07:05   
Hi Rick,

This thread here has a few good suggestions, including:
<Body onLoad=window.refresh>

Good luck.

_____________________________

Kitka
**It is impossible to make anything foolproof because fools are so ingenious.**


(in reply to RickP)
RickP

 

Posts: 693
Joined: 11/13/2004
From: Kent, U.K.
Status: offline

 
RE: Refresh page onload ONCE ONLY - 12/6/2004 8:30:16   
Thanks Kitka

I previously tried all those options! The Body onLoad doesn't do the trick if someone returns to the page using either favs or back-button. The javascript one just sent the browser into a furious array of milisecond refreshes! The 'no cache' one didn't seem to do much - maybe it only works if the page hasn't already been previously cached - no good for return visitors.

It seems that some have asked the question "why?" does someone want to do this. I am thinking that it must be a well-used trick all over the web but just can't find how to do it but maybe I'm going about what I want to achieve wrongly???

My reason is simply that I want all repeat visitors to see the latest content on the page not their previously cached version. Am I missing a more obvious way to achieve this? - Anyone?

Thanks again, Rick

(in reply to Kitka)
Kitka

 

Posts: 2520
Joined: 1/31/2002
From: Australia
Status: offline

 
RE: Refresh page onload ONCE ONLY - 12/6/2004 8:50:00   
An alternative?
<body onLoad="if (location.href.indexOf('reload')==-1) location.replace(location.href+'?reload')">


_____________________________

Kitka
**It is impossible to make anything foolproof because fools are so ingenious.**


(in reply to RickP)
Giomanach

 

Posts: 6136
Joined: 11/19/2003
From: England
Status: offline

 
RE: Refresh page onload ONCE ONLY - 12/6/2004 8:51:38   
The other option is to give the user the option to refresh the page:

<a href="#" onClick="window.refresh();">Refresh</a>

:)

_____________________________




(in reply to Kitka)
RickP

 

Posts: 693
Joined: 11/13/2004
From: Kent, U.K.
Status: offline

 
RE: Refresh page onload ONCE ONLY - 12/6/2004 9:45:42   
Kitka

Yes, that seems to do it, so long as it is a new browser session - it doesn't work when using back/fwd on the browser but that's not so important - big thanks:) You should post this in the other thread we were looking at :)

Dan, I was trying to avoid a 'click here' option but am grateful for your suggestion too.

Thanks all

Rick

(in reply to Giomanach)
Page:   [1]
OutFront Discoveries

All Forums >> Web Development >> General Web Development >> Refresh page onload ONCE ONLY
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts