|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Generate data entry and reporting .NET Web apps in minutes, straight from your database. Read our FREE whitepaper “Build Web 2.0 Applications Without Hand-Coding” Download now! |
|
#1
|
||||
|
||||
|
changing time locale.....
Ok,
I am using <% Locale = Session.LCID Session.LCID = &H1033 Response.Write FormatDateTime(Time) Session.LCID = Locale %> as I am hosted on a US server, but I need to display the time in GMT. This code still displays the server time though. Would it be better to just display <%=Time()%> and then knock 5 hours off the US time? If so, would <%Time(-5)%> work? |
|
#2
|
|||
|
|||
|
How about
Code:
DateAdd("h",-5,Time)
but as I always say Javascript is much better for ASP than VBScript Code:
<script language="javascript" runat="server"> var objDate = new Date(); var d = objDate.toGMTString() </script>
__________________
-- ngibsonau |
|
#3
|
||||
|
||||
|
thankyou. That works good.
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > changing time locale..... |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|