Child pages
  • Working with Dates (and timezones)

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Now if you have not calendar times but more like a birthday (you want to just specify a day in a year not time) then you should check "Use as LocalDateTime" this means that where ever you go the date should be treated the same (formatted).  What this means is that instead of sending over the date string as: 2019-11-01T12:00:00+01:00 we send it over without a timezone info: 2019-11-01T12:00:00 this means that the client can only assume this date is in its timezone (so it assumes 2019-11-01T12:00:00+02:00). Then the formatted time that the user is presented to will just be  2019-11-01 12:00 without any "conversion" as it seems.

Problem is that now we do convert. , because now if you would ask the getTime() in milliseconds from it, it would be different, it would be 1 hour in milliseconds less. Because we kind of removed 1 hour from it  (the difference between the server +1 and the clients +2)

...