Viewing 15 posts - 1 through 15 (of 16 total)
  • Author
    Posts
  • piotras100 Friend
    #168043

    Today I have noticed that actual date in left upper corner of the template is displaying wrong. Day (as number and as short name) is from yestreday 31 ŚR, but now we have 01 CZW. Name of the month WRZ is correct.

    I don’t know how to correct this…


    1. wrong-day
    chavan Friend
    #409958

    Thats is a Last updated Date not the current date. Do you want it to show current date ? please advice

    piotras100 Friend
    #410064

    There must be some kind of misunderstanding…

    First of all I’m not talking about last update date (2). I’m talking about current date (1). It seems to me, that I have never seen in box (1) other than current date. Until today, few minutes after midnight. Now the date is OK.

    Let me explain it step by step…

    Yesterday there was correct date 31 SIER 2011 (ŚR) = 31 AUG 2011 (WED). About 20 minutes after midnight there was strange date: 31 WRZ 2011 (ŚR) = 31 SEPT 2011 (ŚR) but in reality it was 01 WRZ 2011 (CZW) = 01 SEPT 2011 (Thu). Now (18:22) date shown in this box is correct.

    And another important thing: no matter if this box is showing actual or last update date, but THERE IS NO 31 September in calendar. This is not all… how it possible that last update date could display date 30 days in the future from now?

    So the problem is that for some time after midnight this date was showing WRONG date, date that you even can’t find in the calendar.
    For me it looks like Month was updated correctly, but change in number and name of the Day was delayed one or more hours. I don’t know exactly how long it was delayed because I went to bed.


    1. data
    piotras100 Friend
    #410195

    On Friday after midnight once again the Day (number and name) was incorrect (the same as day earlier). Now, at 9 in the morning Day is correct. Who knows why? Who knows how to correct this? I want correct Day exactly when in begins, not hour or two later 😉

    khoand Friend
    #410198

    Hi,
    You try replace this code from /templates/ja_teline_iv/blocks/topbar.php


    <p class="ja-day clearfix">
    <?php
    echo "<span class="day">".JText::_(strtoupper(date ('D')))."</span>";
    echo "<span class="month">".date ('m')."</span>";
    echo "<span class="date">".date ('d')."</span>";
    echo "<span class="year">".date ('Y')."</span>";
    ?>
    </p>

    with


    <p class="ja-day clearfix">
    <?php
    echo "<span class="day">".JText::_(strtoupper(JHTML::date('now', 'd')))."</span>";
    echo "<span class="month">".JHTML::date('now', 'm')."</span>";
    echo "<span class="date">".date ('d')."</span>";
    echo "<span class="year">".date ('Y')."</span>";
    ?>
    </p>

    – Delete all of files of /cache and /t3-assets folder

    piotras100 Friend
    #410376

    I have replaced my code with yours, but
    1) date is in American format (m-d-y) – earlier it was Polish: d-m-y
    2) now I have number of the month in date, earlier it was short name (in Polish language od course)
    3) when mouse was over the date in place of year there was short name of the day (in Polish language) – now I have number of the day in the month.

    Can you do some modifications to this code, so I will have the same system od date (number od the day – short name of the month – year + short name of the day in place of the year)?

    piotras100 Friend
    #410378

    I have made some modifications to your code:

    <p class=”ja-day clearfix”>
    <?php
    echo “<span class=”day”>”.JText::_(strtoupper(JHTML::date(‘now’, ‘D’))).”</span>”;
    echo “<span class=”date”>”.date (‘d’).”</span>”;
    echo “<span class=”month”>”.JHTML::date(‘now’, ‘M’).”</span>”;
    echo “<span class=”year”>”.date (‘Y’).”</span>”;
    ?>
    </p>

    Now I have the date as earlier. After midnight I will check if problem with wrong day will occur once again…

    khoand Friend
    #410519

    If you have still the problem, you inform me. I will help you to solve it.

    piotras100 Friend
    #410596

    Now its 50 minutes after midnight. Still we have Day (as number and as short name) from yesterday. Tonight I have to work till morning, so I will check when the Day will change to the correct 05 PN (PoNiedziałek = Monday).

    piotras100 Friend
    #410600

    One hour and 5 minutes afret midnight…

    Number of the Day is still from yesterday (04) but short name od the Day is correct now PN (Monday). Next info few minutes after 2 am.

    piotras100 Friend
    #410607

    It’s 2:06 am. Still I have wrong day number (04) and correct short name of the day.

    piotras100 Friend
    #410610

    Well… after deleting all files in t3-assets foder and all files in cache folder, finally the number of the Day is now correct.

    But I don’t want to do this everyday one minute after midnight 😉

    khoand Friend
    #410790

    You replace


    <p class="ja-day clearfix">
    <?php
    echo "<span class="day">".JText::_(strtoupper(date ('D')))."</span>";
    echo "<span class="month">".date ('m')."</span>";
    echo "<span class="date">".date ('d')."</span>";
    echo "<span class="year">".date ('Y')."</span>";
    ?>
    </p>

    with

    <p class="ja-day clearfix">
    <?php
    echo "<span class="day">".JText::_(strtoupper(JHTML::date('now', 'D')))."</span>";
    echo "<span class="month">".JHTML::date('now', 'm')."</span>";
    echo "<span class="date">".JHTML::date('now', 'd')."</span>";
    echo "<span class="year">".JHTML::date('now', 'Y')."</span>";
    ?>
    </p>

    piotras100 Friend
    #410815

    OK. I will do it. There is 3 hours to midnight in Poland, so we can check this soon. 😉

    Thanks!

    piotras100 Friend
    #410841

    Day (number and short name) has changed 1 or 2 minutes after midnight. For me it’s OK 🙂
    Thanks for help.

Viewing 15 posts - 1 through 15 (of 16 total)

This topic contains 16 replies, has 3 voices, and was last updated by  khoand 13 years, 1 month ago.

We moved to new unified forum. Please post all new support queries in our New Forum