ClientTime: Based on Client's computer? Or just their time zone?

I want to create document ID’s that incorporate date/time indicators based on the client’s time zone. However, I am reluctant to rely on the client’s computer’s data & time settings. With that said, does the Websession.ClientTime function compute ClientTime based on server time adjusted by client’s time zone, or does it fully rely on the client’s computer? And if only the time zone - where does the client’s time zone information get retrieved from? IP address? Client’s computer? other?

Not sure I follow what you’re trying to do with the doc id ?

I’ve worked on several projects where using the servers time is the best option because if person A is in one timezone( say MST) and person 2 is on something very different(say Chinas) then you have to start considering whether daylight is in effect on a given date etc

If everything is in “server time” then you don’t have quite the same issue

Secondly I’d avoid having an ID with embedded meaning (like a date)
It should be an id and that document has “properties” one of which is the creation date / time maybe in UTC

[quote]If everything is in “server time” then you don’t have quite the same issue

Secondly I’d avoid having an ID with embedded meaning (like a date)
It should be an id and that document has “properties” one of which is the creation date / time maybe in UTC[/quote]

+1

If you absolutely must provide local time, then you simply write a function that converts server time to local time based on the differential between the server and local (user) time zone. You may want to have a look at the ISO 8601 specification if you need to do multiple time manipulations and presentations.

All good thoughts. Thanks.
The questions and comments lead me to believe that no one knows the answer to the question.

I am replacing a system where the users are used to their documents numbered with an element of date - so I would like to stay true to the user if possible.

I can clearly do the calculation to adjust server time to local time - but users will ultimately be in different time zones and I would like to be able to reliably compensate for this. I have already taken provisions to assure uniqueness, so I am not worried about different users in different time zones having the same date component in the document id.

So, back to the original intent… what is the most reliable way to know the time zone that a client is in?

Websession.ClientTime is time that was from the LAST message from the clients web browser
The client sends this & we parse it
So it does use the client 's clock and relies on their clock being set properly

You can’t for 100% certain KNOW what time zone the client is in
If the computer that the browser is running on has the wrong date & time & location set you have no way of knowing
The time from the client comes back with a GMT offset in it and that’s all you have at your disposal

Thank you. It sounds like relying on the server (or some server) is definitely the right direction.

Yeah you have a really had time being 100% accurate with determine the client commuters “correct” time since there’s a limited amount of information you have to determine it from