I have to format date/time in my gwt app with specific timezone, which is loaded from the server. Possible timezones are like this GMT, GMT+1, GMT-2 etc…
Up to now i used DateTimeFormat to format my timestamps, and they used client’s locale.
PLease help.
You can format in any timezone you want with
DateTimeFormat, you just have to pass it as the second argument to theformatmethod.And to obtain a
TimeZoneobject, depending on how you want to present the timezone information (if ever) in the formatted date/time, you can use eithercreateTimeZone(int)orcreateTimeZone(String)(getting the string out ofTimeZoneConstants).