Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Time Script

Status
Not open for further replies.

ledcomp

Technical User
Jul 9, 2006
2
US
I am trying to write a Java script that will be in an html page. The script needs to tell us when it is 4:30 in different time zones so that we can make any last minute calls before they close. So at 1:30 it will tell us that 4:30 is coming up in New York so make your calls now.

Thanks for your help in advance

Dave
 
What have you tried so far?

Given that at almost every hour, on the half hour, it'll be 4:30 somewhere in the world, why not simply create an hourly timer?

Hope this helps,
Dan



Coedit Limited - Delivering standards compliant, accessible web solutions

[tt]Dan's Page [blue]@[/blue] Code Couch
[/tt]
 
I have not come close... lol
All I have now is some code that will tell days from a set date.
I need hours.

Can you point me in the right direction to make an hourly counter?

Thanks
 
Just convert the date to (using setDays, etc.) localtime, then add 360000 for every hour, then create a new date object from the new locatltime (using getDays, etc.).
 
Sorry, there are 3600000 milliseconds in an hour.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top