ATutor

Learning Management Tools







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


Dates dont show up in the right format


  • 2008-04-06 17:59:28

    Dates dont show up in the right format

    I recently updated to 1.6 and I have noticed that dates are showing as long numbers, you know, the number of seconds that have gone by since I don't know when, instead of 06/04/2008 for instance.

    I've noticed it on hte dates for tests, where it says the test is available from 1234545667 to 1234454678.

    I suppose this would be an easy thing to fix but I don't know how to do it.

    I'm using the default 1.6 theme.

    Hopefully you would be able to help me out. Thanks in advance.

  • 2008-04-06 18:18:48

    Re: Dates don't show up in the right format

    I've been looking around and it apparently has something to do with the translation. My deafult language is spanish but if I see the page in english dates show up right.

    I do have the latest spanish translation for 1.6 but according to the website it is 98% done.

    Is there something else I can do? How can I help the translation team?

    I still hope this is something very easy to fix.

    Thanks again.

  • 2008-04-06 19:03:59

    Re: Dates don't show up in the right format

    See the section in the translator documentation on date variables:

    http://www.atutor.ca/atutor/docs/translate.php#replace

  • 2008-04-07 20:27:23

    Re: Dates don't show up in the right format

    Thanks for answering. I checked the translator documentation as suggested but it seems to be ok.

    Announcement dates look ok both in english and spanish. The problem is with the Start and End dates of Tests. Those are Datetime fields in the database, and of course in the database they look fine, but on the Surveys/Test pages they look fine in English but they are shown as numbers in spanish.

    Hopefully you can give me another suggestion.

    Thanks in advance.

  • 2008-04-10 18:31:47

    Re: Dates don't show up in the right format

    I'm sorry to insist but I still have the problem and I would like to know if anyone can help me out.

    Thanks in advance.

  • 2008-04-11 11:18:58

    Re: Dates don't show up in the right format

    Looking at the language database, I see the dates have not been translated in Spanish. You need to turn on translation mode, then translate the missing items.You should just need to copy the English string into the Spanish translation box.

    For example

    startend_date_long_format

    should be

    %%Y-%%m-%%d %%h:%%m

    I have translated the dates in our local database, and republished the language. You should be able to delete the current Spanish from your system then reimport through the ATutor language manager. But, there are still some terms missing from the current Spanish translation. You might volunteer to login to the Translation site and update the Spanish translation, or if you translate the missing terms on your local system, export the language from there and attach it to this thread so we can update our local database.

    In addition to the documentation linked above, look at the Handbook documention included with ATutor for more detail.

  • 2008-04-11 16:40:41

    Re: Dates don't show up in the right format

    Thanks Greg.

    I used tranalation mode and I was able to find the start_date_long_format. After I copied the the enlish string to the necessary variables I was able to see the dates in the right format, however, they were showing the wrong date!

    Looking into it I realized that there is a mistake in the English file for the minutes, because no matter what I set for the start/end dates of tests I was getting "04" all the time. If you see your last post you suggested:

    %%Y-%%m-%%d %%h:%%m

    You can see that you have m for month, which is right, but then you use m again at the end for minutes, and that's wrong, that's why I kept getting "04" since it's april! The right character for minutes is letter "i"

    While that solved the minutes on the dates, I still have a problem with the Start date of a test, it shows the current date and time instead of the actual start date. End date is ok.

    What can I do to fix the start date?

    Thanks again.

  • 2008-04-11 17:40:06

    Re: Dates don't show up in the right format

    My mistake. The final "m" should be "i". There is a full list of potential date format codes you can use if you want to customize the dates further, linked from the translator documentation.

    http://www.atutor.ca/atutor/docs/translate.php#replace

  • 2008-04-11 18:05:35

    Re: Dates don't show up in the right format

    Thanks for your answer Greg, I've seen and learned about the different formats I can give to dates. I thanks you for that.

    But now, could you please suggest what to do with the Start dates of tests showing the current date instead of the actual start date?

    I've looked in the forums but I haven't found any solutions.

    Thanks for your time.