Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Coding Forum


You are currently viewing our Coding Forum as a guest. Please register to participate.
Login



Reply
REfresh @ 12 - is this possible?
Old 11-06-2004, 02:47 PM REfresh @ 12 - is this possible?
Spud In Disguise's Avatar
Super Spam Talker

Posts: 808
Location: UK... where else?
Trades: 0
Hey there. I know it is possible to get a page to automatically refresh every 'x' minutes or seconds, but is it possible to make a page refresh according to time?

I am designing a normal HTML page which is more than likely going to be kept open by users for a long time and since the content will automatically be changed at 12am every night I was wondering if it is possible to set the page to be refreshed at 12:05am, so that my users are guaranteed to have the latest version of the page displayed.

Any help anyone?
__________________

Please login or register to view this content. Registration is FREE
- Fansite

Please login or register to view this content. Registration is FREE
- Blog
Spud In Disguise is offline
Reply With Quote
View Public Profile Visit Spud In Disguise's homepage!
 
 
Register now for full access!
Old 11-10-2004, 09:15 PM
Arctic Fox's Avatar
Junior Talker

Posts: 4
Location: Murmansk
Trades: 0
Well there's a couple issues here first;
  • Are people really sitting on your single page for hours on end?
  • What time is it where? 12:05am your time may be 8:05pm somewhere else - this problem may have to be handled server-side.
  • Have you thought of using the META tag refresh?
  • How about just having JavaScript or META tag refresh every 3 hours?

Don't get me wrong, it can be done (with a bit of work)... but is it really required?
__________________

Please login or register to view this content. Registration is FREE

~ Roads? Where we’re going we don’t need, roads! ~
Arctic Fox is offline
Reply With Quote
View Public Profile Visit Arctic Fox's homepage!
 
Old 11-10-2004, 09:18 PM
Anacrusis's Avatar
Defies a Status

Posts: 2,099
Name: Adam
Location: Colchester CT
Trades: 0
Just remind your visitors to press F5 at midnight.. problem solved
Anacrusis is offline
Reply With Quote
View Public Profile
 
Old 11-11-2004, 04:52 PM
Spud In Disguise's Avatar
Super Spam Talker

Posts: 808
Location: UK... where else?
Trades: 0
It's actually not going to be used on a website, ti's in an application that displays web pages in a windows app box. So it looks like a normal program but is actually a web page, therefore people will be on it for hours - also it is designed for my town website so it only applies to people in my time zone...
__________________

Please login or register to view this content. Registration is FREE
- Fansite

Please login or register to view this content. Registration is FREE
- Blog
Spud In Disguise is offline
Reply With Quote
View Public Profile Visit Spud In Disguise's homepage!
 
Old 11-11-2004, 08:59 PM
Arctic Fox's Avatar
Junior Talker

Posts: 4
Location: Murmansk
Trades: 0
I think I may have found something on the net that you'd be able use.

(edited for your situation):

Code:
<html>
<head>


<script type="text/javascript">
<!--
var GoOff_Hour=00; //24 hour clock
var GoOff_Minute=05;

// current set at 12:05 AM
var Armed=true;

function CheckTime() {
var now = new Date();

if (now.getHours()>=GoOff_Hour && now.getMinutes()>=GoOff_Minute && Armed==true) {
window.location.reload(); 
Armed=false;
}

setTimeout("CheckTime()",1000)


}
//-->
</script> 


</head>

<body onload="CheckTime();">

</body>

</html> 
__________________

Please login or register to view this content. Registration is FREE

~ Roads? Where we’re going we don’t need, roads! ~
Arctic Fox is offline
Reply With Quote
View Public Profile Visit Arctic Fox's homepage!
 
Reply     « Reply to REfresh @ 12 - is this possible?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.39917 seconds with 12 queries