Local Times

Results 1 to 3 of 3

Thread: Local Times

  1. #1
    Join Date
    Dec 1969

    Default Local Times

    I have hosted my files in US Server and the users are all in India. Whenever the user post any new comment or query, the time follows that of US how can i follow the indian time...???

  2. #2
    Join Date
    Dec 1969

    Default Adjust it in your code!

    Let&#039;s say that the US site is at GMT - 8 hours. Let&#039;s say India is at GMT + 6.5 hours. So the difference, altogether, is 14.5 hours.<BR><BR>So you just do:<BR><BR>&#060;%<BR>IndiaTime = DateAdd( "h", 14.5, Now() )<BR>%&#062;<BR><BR>And now use IndiaTime in place of Now() in all your coding.<BR><BR>You might also want to change the Locale setting. Do<BR><BR>&#060;%<BR>Session.LCID = xxxx<BR>%&#062;<BR>where xxxx is the proper LCID for India. You can find a list of LCIDs in "Miscellany" in the VBScript reference manual.<BR><BR>Oh, what the heck. Here:<BR>http://msdn.microsoft.com/library/default.asp?url=/library/en-us/script56/html/vsmsclcid.asp<BR><BR>Looks like 1081 is the LCID for Hindi. If you prefer using British-style English, then use 2057.<BR><BR>

  3. #3
    Join Date
    Dec 1969

    Default RE: Local Times

    Populate a hidden field from javascript with local datetime value.<BR>Populate it on onSubmit action<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts