tzortzik
tzortzik

Reputation: 5133

Date and time dependant client server web apps

I read some articles regarding web applications which depend on the date and time and geographical position.

I am interested in finding here a few best practices and even solutions for java web applications which client side happens to be on Angular.

I am looking for the best way to store the dates and times in my database so that I can determine their values based on user's location. We have some help here from the Javascript side which can determine the user's timezone.

Any advices, best practices and solution would be great.

I want to know from your experience what is the best way to do this thing because each article I read had a slightly different solution and that small diference caused iasuea later.

Upvotes: 0

Views: 38

Answers (1)

Alex
Alex

Reputation: 4934

You may want to check out Moment.js, and specifically the Timezone add-on if you haven't already... it will take ISO 8601 datetime formatted string by default, the industry standard on any platform.

The Timezone is useful in dealing with timezones and converting between them etc.

This format encodes the UTC time with a timezone part, with high precision.

Upvotes: 1

Related Questions