Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • Ninja Lead Moderator
    #972396

    Hi

    You can have a look at templates/ja_charity/acm/countdown/tmpl/style-1.php file with code

    <?php echo $date->format('Y/m/d'); ?>

    It’s inheriting the server time so kindly check this value set on your site.

    Regards

    liam011 Friend
    #974392

    Hey Ninja,

    Sorry for the late reply and thanks for your help. I have looked into it currently the setting for server time is correctly setup on Joomla setting – set to London. Do you have any further ideas what might be the cause for this?

    Ninja Lead Moderator
    #974847

    Hi
    I changed some code from templates/ja_charity/acm/countdown/tmpl/style-1.php file and you can get it from my attached file .
    Take a backup of the original file before replacing or applying the changes .

    Let me know if it helps you .


    1. style-1.php_.zip
    liam011 Friend
    #975064

    Hey,

    As instructed I made a backup copy of style-1.php and replaced it with style-1.php you provided. I created an event for 11th October – 12th October the countdown timer displayed all 0 Days 0 Hours 0 Min 0 Sec it didn’t seem to fix this.

    Do you think it’s something you will need to look into a bit more in depth (i.e. login onto the web as admin)?

    P.S I have reverted back to the original style-1.php

    Thanks

    Ninja Lead Moderator
    #975176

    Hi
    You can give me the URL of your site with admin login details and FTP account via private reply.
    I will check further.
    Regards

    liam011 Friend
    #975291
    This reply has been marked as private.
    Ninja Lead Moderator
    #975305
    This reply has been marked as private.
    liam011 Friend
    #975315
    This reply has been marked as private.
    Ninja Lead Moderator
    #975518

    Hi

    I checked your time setting on Upcoming Events module and found its in the past date (2016-9-4).
    I set it with format yy/mm/dd: 2016-10-13 (Future date )and now you can see it’s working fine on your site .
    Kindly check and update .

    Regards


    1. Screen-Shot-2016-10-12-at-09.21.49
    2. Screen-Shot-2016-10-12-at-09.18.13
    liam011 Friend
    #975602
    This reply has been marked as private.
    Ninja Lead Moderator
    #975619

    You can fix this bug on Event detail page on your site with the solution below

    Open templates/ja_charity/html/layouts/joomla/content/item/event.php file

    find and change

    <?php 
      if(strtotime(date("Y/m/d")) < strtotime($date->format('Y/m/d'))) { 
    ?>
    <script type="text/javascript">
      (function($){
      jQuery(document).ready(function($) {
        $('.countdown').downCount({
            date: '<?php echo $date->format('Y/m/d'); ?>',
            offset: +10
        }, function () {
            alert('We Ready To Rock Your World');
        });
      });
    })(jQuery);
    &lt;/script&gt;
    <?php } ?>

    to

    <?php 
      $config = JFactory::getConfig();
      $timezone = new DateTimeZone($config->get('offset'));
      $date= new DateTime($helper->get('downdate'), $timezone);
      $offset = $timezone->getOffset($date)/3600;
    
      if(strtotime(date("Y/m/d")) < strtotime($date->format('Y/m/d'))) { 
    ?>
    <script type="text/javascript">
      (function($){
      jQuery(document).ready(function($) {
        $('.countdown').downCount({
            date: '<?php echo $date->format('Y/m/d'); ?>',
            offset: +<?php echo $offset; ?>
        }, function () {
            alert('We Ready To Rock Your World');
        });
      });
    })(jQuery);
    &lt;/script&gt;
    <?php } ?>

    Hope it helps

    liam011 Friend
    #975662
    This reply has been marked as private.
    Ninja Lead Moderator
    #975851

    I fixed the problem directly on your site from templates/ja_charity/html/layouts/joomla/content/item/event.php file and you can compare it with original file. Now, you can see it’s working as well on your site.


    1. Screen-Shot-2016-10-13-at-10.00.37
    liam011 Friend
    #975940

    Hey Ninja,

    Thanks for your help and patience, really happy with the service.

Viewing 14 posts - 1 through 14 (of 14 total)

This topic contains 14 replies, has 2 voices, and was last updated by  liam011 8 years, 1 month ago.

The topic ‘JA Charity countdown’ is closed to new replies.