How to add END_DATE into Email Template

  • waisir
  • Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 8 months ago #101959 by waisir
Hi guys, in the configuration file for messages, the template triggers [REGISTRATION_DETAIL] tag. The registration tag shows only start date but not end date. How can we modify to make it show end date as well?

From the tag it triggers the individual_registration.php file where there's this part:
Code:
<?php if ($this->config->show_event_date) { ?> <tr> <td class="title_cell"> <?php echo JText::_('EB_EVENT_DATE') ?> </td> <td class="field_cell"> <?php if ($this->rowEvent->event_date == EB_TBC_DATE) { echo JText::_('EB_TBC'); } else { echo JHTML::_('date', $this->rowEvent->event_date, $this->config->event_date_format, $param) ; } ?> </td> </tr>

Can we add another <tr><td> that shows the event end date as well please?

Please Log in or Create an account to join the conversation.

More
8 years 8 months ago #101970 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic How to add END_DATE into Email Template
Not sure what version you are using. In the latest version, we have event end date by default. The code in latest version is something like this:
Code:
<?php if ($rowEvent->event_end_date != $nullDate) { if (strpos($rowEvent->event_end_date, '00:00:00') !== false) { $dateFormat = $config->date_format; } else { $dateFormat = $config->event_date_format; } ?> <div class="<?php echo $controlGroupClass; ?>"> <label class="<?php echo $controlLabelClass; ?>"> <?php echo JText::_('EB_EVENT_END_DATE') ?> </label> <div class="<?php echo $controlsClass; ?>"> <?php echo JHtml::_('date', $rowEvent->event_end_date, $dateFormat, null); ?> </div> </div> <?php } }

Maybe you can try to check the code from latest version and apply the necessary change there

Tuan
The following user(s) said Thank You: waisir

Please Log in or Create an account to join the conversation.

  • waisir
  • Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 8 months ago #101975 by waisir
Replied by waisir on topic How to add END_DATE into Email Template
thanks Tuan for the reply!
Well u know me, i had 2 licenses with u. one is recent which is fine and up to date. But i had one which is dated way back 1.5.2 which is a dinasour. the client pops up in the middle of nowhere requesting this small tweak.

i tried the below:
Code:
<tr> <td class="title_cell"> <?php echo JText::_('Event End Date') ?> </td> <td class="field_cell"> <?php if ($this->rowEvent->event_date == EB_EVENT_END_DATE) { echo JText::_('EB_TBC'); } else { echo JHTML::_('date', $this->rowEvent->event_end_date, $this->config->event_date_format, $param) ; } ?> </td> </tr>

But the value column came out a date which is totally unrelated to the actual end date. damn weird haha..
Please advise what can we do on this quick fix as i'm now pushing the client to revamp the site entirely + a new version license (3rd license!) since is so obselete.

Please Log in or Create an account to join the conversation.

More
8 years 8 months ago #101977 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic How to add END_DATE into Email Template
Do you really think I remember the code of that very outdated Events Booking version, LOL. Okay, submit a support ticket sending us super admin account and FTP account of your site. I will try to help with this code modification on tomorrow

Tuan
The following user(s) said Thank You: waisir

Please Log in or Create an account to join the conversation.

  • waisir
  • Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 8 months ago #101979 by waisir
Replied by waisir on topic How to add END_DATE into Email Template
im so embarrased to ask for help on this since this is obselete. i checked on the weird date and i finally realised. the date called is TODAY's DATE! :woohoo: :woohoo: :lol: :lol:

Well that's weird to the max! LOL

i' will also submit a ticket too. Thanks for hearing me out despite an outdated code/license for this.

Please Log in or Create an account to join the conversation.

Moderators: Tuan Pham Ngoc