ATutor

Learning Management Tools







Pages:1 2 3 4 5 6 7 8 9 10 11 12 13 14 15


Is there a global way to change the time


  • 2008-04-11 17:07:45

    Is there a global way to change the time

    Hi everyone, this is the thing. My server runs MySQL 4.1.22, it's a shared hosting server in Canada. While a part of the year I have the same time as they do, EST, now they are 1 hour ahead because of Daylight Savings Time.

    I cannot use the TimeZone features in Atutor because MySQL is 4.1.22 but I would like to substract an hour from the time Atutor shows because all the times show up as one hour ahead which is especially annoying for test start and end dates.

    I hope I have made myself clear, and any help would be really appreciated.

    Thanks in advance.

  • 2008-04-11 17:41:44

    Re: Is there a global way to change the time?

    I think that solution for your situation and many otehr situations where there are differences in time zones different from teh server time and access to administration of server itself, is to create small utility that will be able to show defined time offset from the servers time.
    Some PHPBased systems do have that and I think that it is not too hard to implement it.

    Thanks,

    Vedran

  • 2008-04-11 18:13:05

    Re: Is there a global way to change the time?

    You could hack the include/vitals.inc.php file. Look for

    [php]

    if ($_config['time_zone']) {

    [/php]

    Sounds like the date on your server is incorrect, ATutor's date is based on it, so you could have your ISP reset the date, an hour ahead.

    We are looking into ways to improve with timezone support.

  • 2008-04-11 18:26:18

    Re: Is there a global way to change the time?

    You are right of course, the server time is one hour ahead of mine and that's why I have the difference.

    I've contacted my ISP and I hope they can change the time but I doubt because it is a shared server and they've told me they cannot change the time for me. So, in my other websites where I know the php code I'm using a file to set the time and refer to it from anywhere else.

    From what you suggest I think I can accomplish the same thing in the vitals.inc.php. Would it be enough to susbstract 3600 from $_config['time_zone']?

    Sorry to bother so much, I'll try to solve it with my ISP first.

    Thanks again for your time.

  • 2008-04-11 18:29:25

    Re: Is there a global way to change the time?

    It may be good to see solution if you can make it so we can put it in vitals.inc.php

    thanks,

    vedran