Welcome, Guest
Username: Password: Remember me
JO Facebook Events Pro

TOPIC: Wrong time zone?

Wrong time zone? 9 years 9 months ago #913

The module is showing the wrong times. I have a Facebook event at 19:30 on 3 July but it shows on the module as 01:30 on 4 July. Can you please help me fix this?
The administrator has disabled public write access.

Wrong time zone? 9 years 9 months ago #915

  • Super User
  • Super User's Avatar
  • OFFLINE
  • Administrator
  • Posts: 3519
  • Thank you received: 278
  • Karma: 65
Hello Josh Cullen
Can you send me joomla administrator via contact form? So we can check and help you
Best regards
Bach Pham
The administrator has disabled public write access.

Wrong time zone? 9 years 9 months ago #983

I've got the same issue.

Added an Event at 18.00 CEST (CET Summertime)
Also Global Configuration in Joomla Admin set to "Europe/Stockholm".

Still the Event is shown to start 16.00 CEST.

See these URLs for comparison:
Facebook Event: www.facebook.com/events/430032687139674/
Website: kerikokund.se/index.php/aktiviteter

Any solution made to this, or configuration?
Last Edit: 9 years 9 months ago by Kjell Korshavn.
The administrator has disabled public write access.

Wrong time zone? 9 years 9 months ago #985

  • Super User
  • Super User's Avatar
  • OFFLINE
  • Administrator
  • Posts: 3519
  • Thank you received: 278
  • Karma: 65
info@kerikoweb.se wrote:
I've got the same issue.

Added an Event at 18.00 CEST (CET Summertime)
Also Global Configuration in Joomla Admin set to "Europe/Stockholm".

Still the Event is shown to start 16.00 CEST.

See these URLs for comparison:
Facebook Event: www.facebook.com/events/430032687139674/
Website: kerikokund.se/index.php/aktiviteter

Any solution made to this, or configuration?
Hello
Can you send me joomla administrator via contact form? So we can check and help you
Or in file module/mod_jo_facebookevents_pro/tmpl/default.php
in line 73 added code
$start_time = substr($fbevent["start_time"], 0, -5);
$end_time = substr($fbevent["end_time"], 0, -5);
in line 79 changed
<time itemprop="startDate" datetime="<?php echo date('Y-m-d', strtotime($fbevent["start_time"]))?>"></time>
To
<time itemprop="startDate" datetime="<?php echo date('Y-m-d', strtotime($start_time))?>"></time>

In line 94 changed
<em class="evo_date"><?php echo date('d', strtotime($fbevent["start_time"]))?><span><?php if($fbevent["end_time"] !=""){?> - <?php echo date('d', strtotime($fbevent["end_time"]))?><?php }?></span></em>
To
<em class="evo_date"><?php echo date('d', strtotime($start_time))?><span><?php if($fbevent["end_time"] !=""){?> - <?php echo date('d', strtotime($end_time))?><?php }?></span></em>

in line 102 changed
<em class="evcal_time"><?php echo date($params->get('dateformat'), strtotime($fbevent["start_time"]))?><?php if($fbevent["end_time"] !=""){?> - <?php echo date($params->get('dateformat'), strtotime($fbevent["end_time"]))?><?php }?></em>
To
<em class="evcal_time"><?php echo date($params->get('dateformat'), strtotime($start_time))?><?php if($fbevent["end_time"] !=""){?> - <?php echo date($params->get('dateformat'), strtotime($end_time))?><?php }?></em>

in line 151 changed
<h3 class="evo_h3"><?php echo JText::_('MOD_JO_FACEBOOKEVENTS_PRO_TIME')?></h3><p><?php echo date($params->get('dateformat'), strtotime($fbevent["start_time"]))?><?php if($fbevent["end_time"] !=""){?> - <?php echo date($params->get('dateformat'), strtotime($fbevent["end_time"]))?><?php }?></p>
To
<h3 class="evo_h3"><?php echo JText::_('MOD_JO_FACEBOOKEVENTS_PRO_TIME')?></h3><p><?php echo date($params->get('dateformat'), strtotime($start_time))?><?php if($fbevent["end_time"] !=""){?> - <?php echo date($params->get('dateformat'), strtotime($end_time))?><?php }?></p>

Best regards
Bach Pham
Last Edit: 9 years 9 months ago by Super User.
The administrator has disabled public write access.

Wrong time zone? 9 years 8 months ago #999

  • Manuel
  • Manuel's Avatar
  • OFFLINE
  • New Member
  • Posts: 4
  • Karma: 0
I fixed my issue by adding this code on the default.php
date_default_timezone_set('America/Los_Angeles');

just find your time zone and replace it.

Best regards,
MDI!
Last Edit: 9 years 8 months ago by Manuel.
The administrator has disabled public write access.

Wrong time zone? 9 years 8 months ago #1002

  • Super User
  • Super User's Avatar
  • OFFLINE
  • Administrator
  • Posts: 3519
  • Thank you received: 278
  • Karma: 65
Dear mdimannyit
Great solution. Thank you so much
Best regards
Bach Pham
The administrator has disabled public write access.
Time to create page: 0.088 seconds