mojoPortal admin info showing wrong timezone

This is the place to report bugs and get support. When posting in this forum, please always provide as much detail as possible.

Please do not report problems with a custom build or custom code in this forum. If you are producing your own build from the source code and have problems or questions, ask in the developer forum, do not report it as a bug.

This is the place to report bugs and get support

When posting in this forum, please try to provide as many relevant details as possible. Particularly the following:

  • What operating system were you running when the bug appeared?
  • What database platform is your site using?
  • What version of mojoPortal are you running?
  • What version of .NET do you use?
  • What steps are necessary to reproduce the issue? Compare expected results vs actual results.
Please do not report problems with a custom build or custom code in this forum. If you are producing your own build from the source code and have problems or questions, ask in the developer forum.
This thread is closed to new posts. You must sign in to post in the forums.
10/23/2009 2:54:09 AM
Gravatar
Total Posts 116
http://www.zoomicon.com http://birbilis.spaces.live.com http://www.delicious.com/birbilis http://twitter.com/Zoomicon

mojoPortal admin info showing wrong server timezone offset

I have a server set to GMT+2 (GTB [also called EET sometimes I think]) timezone (Greece) but the admin info shows the following at mojoPortal:

 

---------------

 

mojoPortal Version 2.3.1.9 MSSQL

 

Server Time Zone GTB Daylight Time

 

Server Local Time 23/10/2009 10:43:52 πμ

 

Current Time in Greenwich (aka GMT or UTC): 23/10/2009 7:43:52 πμ

 

Server GMT Offset 3

 

Preferred GMT Offset Web.config Setting 2

 

----------------

 

why does it say GMT Offset 3 ? (Do I need to set the GMT preferred offset in user.config to 3 too instead of 2? How do you calculate the offset? is it from a standard .net routine?)

 

see more info on timezones (there it says "GTB Standard Time +02:00 Athens, Istanbul, Minsk"):

http://www.castlesoftware.biz/SpotLight/Spotlight002.htm

 

(btw it's very hard to edit text with the editor always pasting at the start of the text instead of at current position :-(

10/23/2009 1:56:05 PM
Gravatar
Total Posts 18439

Re: mojoPortal admin info showing wrong timezone

Hi George,

Server Time Zone and Server GMT Offset are the actual offsets for the server time. Note that the offset for a given time zone may be different during different times of year, hence the difference between GTB Standard Time with a GMT offset of 2 and GTB Daylight Time with a GMT Offset of 3. Apparently at this time of year it is GTB Daylight.

Similar, where I live its Eastern Daylight Time now so we are -4 GMT, but next month I think we fall back an hour to Eastern Standard Time which is -5 GMT.

Preferred GMT Offset can be set in user.config with

<add key="PreferredGreenwichMeantimeOffset" value="-5.00" />

so if your server local time is the same as your preferred time zone then set it to 3 for now and change it to 2 when Daylight savings time is over.

Like I said in a different thread, now 3.5 .NET has a TimeZoneInfo class that we will use in the future to make it so we don't have to adjust it manually because this class knows how to adjust it automatically.

Best,

Joe

10/23/2009 3:31:29 PM
Gravatar
Total Posts 116
http://www.zoomicon.com http://birbilis.spaces.live.com http://www.delicious.com/birbilis http://twitter.com/Zoomicon

Re: mojoPortal admin info showing wrong timezone

Isn't there any opensource implementation of that class (maybe at mono project) that you could copy and fallback to if the system doesn't provide it (fallback is useful if you want to be sure you use the latest/best/more-secure version of that class in case the copied clone becomes old)?

backwards compatibility is useful if .NET 3.5 isn't installed (say at some shared host) or user doesn't have the appropriate VisualStudio version that provides 3+ .NET compilers, but don't need it personally since we have our own virtual Win2008 R2 server

10/26/2009 2:50:31 PM
Gravatar
Total Posts 116
http://www.zoomicon.com http://birbilis.spaces.live.com http://www.delicious.com/birbilis http://twitter.com/Zoomicon

Re: mojoPortal admin info showing wrong timezone

I was thinking that admins who don't use shared hosting can control the server's time and usually prefer their users to have the same time offset as the server.

So it could have an option to prefer for the users the same timezone as the server or to be able to define an offset against that instead of GMT, although not sure if that's too much since offset would usually be set to 0 (the existing alternative option to define preferred offset against GMT may still be needed for some people who say are in Greece but use shared hosting in the US or something so they can't assume that timezones change together)

You must sign in to post in the forums. This thread is closed to new posts.