Reputation: 4506
I am implementing a timer of n minutes for an event using a jquery plugin as a timer library.
The plugin method expects a finaltime to countdown to, so I am passing the time from the server as the final future time to the client. The plugin compares the server provided time with the client time & starts the countdown.
I am using java Calender class for getting the server time.
The functionality will run fine for a client in my timezone but what if the client is in some other timezone or in a daylight saving.
Should I first fetch the timezone from the client to the server then make modifications in the server time then pass it to the client?
I was wondering what would be the correct approach for this.
Upvotes: 0
Views: 53
Reputation: 241603
Upvotes: 1