• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Ron McLeod
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

Locale specific Time to display

 
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
I am using struts 1.2 and message resources , I want a typical requirement that time to be displayed according to the locale.

In data base we will have GMT so depending on this display local time according to the locale.

Could anyone suggest one approach.. It would be great if the change in jsp or javascript level. because i have so many places we need to take care this.

ThanksInadvance
Madhav
 
Ranch Hand
Posts: 181
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Use the javascript date object. Here is an example if myForm contains a getTimestamp that returns a timestamp in milliseconds.

It will display the time based on the user's time zone.

 
reply
    Bookmark Topic Watch Topic
  • New Topic