Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Time Zones and Users

by thor (Priest)
on Jan 11, 2002 at 10:23 UTC ( [id://137951]=note: print w/replies, xml ) Need Help??


in reply to Time Zones and Users

At my company, we run several instances of a scheduler program all around the world. All any of them care about is 'what is my local time?'. The user makes the adjustment. For instance, I'm in Minneapolis, MN and the scheduler that I'm looking at is in Sydney, Australia. I have to keep track of the time difference (right now, it is 17 hours I think). I think that this is the way to go. If you will be doing anything local to the server, you should be doing everything on the servers time.

Of course, if it really matters to you, you could do some version of an rsh to the remote server to execute a timelocal((localtime())[0,1,2,3,4,5]) and store it in a variable. Do the same thing on the client side, and find the difference between the two. Pass the difference into gmtime to get the difference in hours and minutes (not all timezones are an integer number of hours apart, so the minutes are necessary).

thor

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://137951]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (4)
As of 2024-03-29 10:30 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found