CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • Event Reminder tokens
Pages: [1]

Author Topic: Event Reminder tokens  (Read 1486 times)

mcgeehon

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
  • CiviCRM version: 4.x
  • CMS version: 7.x
  • MySQL version: 5.x
  • PHP version: 5.2.x
Event Reminder tokens
November 28, 2012, 07:28:25 pm
I want to create an event reminder template that will be sent out several hours or a day before an event that reminds people that they registered for an event.

The problem is that I cannot find any tokens in the 'User Driven Messages' template builder that relate to events.  I do however see several event templates in the 'System Workflow Messages' list, however I don't want to re-purpose those templates, but rather add a new one.

Is there an example or a way to send out a message that will reference an event that I can use with 'schedule reminders'?

Otherwise, I am forced to be generic in the email that I send out to event participants.


Thanks

NASACT

  • I post frequently
  • ***
  • Posts: 289
  • Karma: 9
    • National Association of State Auditors, Comptrollers and Treasurers
  • CiviCRM version: 4.2.2
  • CMS version: Drupal 7
  • MySQL version: 5.1.58 (ubuntu)
  • PHP version: 5.3.5
Re: Event Reminder tokens
November 29, 2012, 09:38:46 am
I think you might be looking for the scheduled reminders within the event itself. 4.2 you can create a reminder for the event and tailor it accordingly.  Does that help?
-AJ
My GChat - azon21@gmail.com -  This is where you can find me most days!

mcgeehon

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
  • CiviCRM version: 4.x
  • CMS version: 7.x
  • MySQL version: 5.x
  • PHP version: 5.2.x
Re: Event Reminder tokens
November 29, 2012, 12:11:08 pm
Yeah, I am aware of how to create a reminder for a specific event.  The issue is that when you are creating several events a week across 3 continents, it would be nice if we could create a generic event reminder email that will go out with every event and remind registered participants several hours before the event.

Does anything like that exist?  Coming in a future release?

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Event Reminder tokens
November 29, 2012, 02:54:49 pm
Seems like you can do 'generic' scheduled reminders on events BY EVENT TYPE in 4.2. Have you tried that.
Protect your investment in CiviCRM by  becoming a Member!

mcgeehon

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
  • CiviCRM version: 4.x
  • CMS version: 7.x
  • MySQL version: 5.x
  • PHP version: 5.2.x
Re: Event Reminder tokens
November 29, 2012, 07:18:03 pm

Yes, I can send a generic response to events.  That part was fairly straight forward.  I would like to reference the name of the event, date and similar in the email that goes out.  Similar to the way that you can insert a contact name and other custom tokens into the email.

I can see why that event tokens might not have been included, as it might have been difficult to identify the event for which the email was being generated.

What is confusing is that there were about 4 pre-built templates for events in 4.2 under the 'System Workflow Messages' that relate to event registration, confirmation etc.  It would be great it one was delivered for event reminders.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Event Reminder tokens
November 29, 2012, 07:48:02 pm
there are event tokens that can be used during scheduled reminders. Can you try adding:

event.

'event_type', 'title', 'event_id', 'start_date', 'end_date', 'summary', 'description', 'location', 'info_url', 'registration_url', 'fee_amount', 'contact_email', 'contact_phone'

to your scheduled reminder and see if it evaluates nicely.

Not sure if we've integrated this into our editor ("insert tokens") functionality, but definitely something that needs doing

lobo

A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

mcgeehon

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
  • CiviCRM version: 4.x
  • CMS version: 7.x
  • MySQL version: 5.x
  • PHP version: 5.2.x
Re: Event Reminder tokens
December 04, 2012, 01:24:15 pm
Thanks Lobo, that works!   

I think that adding these (and any others that are missing) to the 'insert token' would be much appreciated.


Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Event Reminder tokens
December 04, 2012, 01:49:39 pm

any chance u (or your consultant / developer) can take a look at the scheduled reminders code and provide a patch for this.

The event and activity tokens are limited and available only in that flow. I think the insert tokens stuff is generic and needs to be extended to make it feature specific

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Event Reminder tokens
December 11, 2012, 10:34:03 am
Hmm - event related tokens appear to be available via Insert Tokens pop-up in both 4.2 and 4.3. Screenshot attached. The one thing that isn't currently in place is filtering the available tokens based on the type of reminder (e.g. only show event related reminders if Entity for reminder is Event Type or Event Name.
Protect your investment in CiviCRM by  becoming a Member!

sonicthoughts

  • Ask me questions
  • ****
  • Posts: 498
  • Karma: 10
Re: Event Reminder tokens
January 03, 2013, 02:35:51 pm
Can these tokens be used in User Templates?  Would be nice to include an "upcoming events" section for a newsletter.  If we can add a drupal view, that would cover it nicely.

kung

  • I’m new here
  • *
  • Posts: 17
  • Karma: 0
  • CiviCRM version: 5
  • CMS version: Drupal 6 or 7
  • MySQL version: 5
  • PHP version: 5
Re: Event Reminder tokens
January 24, 2013, 07:40:34 am
The event summary token is not being populated on my site (Drupal 7, MySQL 5.5, php 5.3.19, Civicrm 4.2).   My code has the code used in the patch.  And when I print out the tokenParams in /CRM/Core/BAO/ActionSchedule.php my summary token is there.
How can I trace and find out where it's going wrong?

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Event Reminder tokens
January 24, 2013, 10:30:02 am
Quote from: sonicthoughts on January 03, 2013, 02:35:51 pm
Can these tokens be used in User Templates?  Would be nice to include an "upcoming events" section for a newsletter.  If we can add a drupal view, that would cover it nicely.

Event tokens are keyed to a specific event by the Schedule Reminders code / flow - so they can't be used to generate a list for a newsletter. I don't think anyone has developed a module to add a view to a CiviMail mailing - but that would be pretty cool (would involve developing a new custom token via the token Hook.
Protect your investment in CiviCRM by  becoming a Member!

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Event Reminder tokens
January 24, 2013, 10:36:38 am
Quote from: kung on January 24, 2013, 07:40:34 am
The event summary token is not being populated on my site (Drupal 7, MySQL 5.5, php 5.3.19, Civicrm 4.2).   My code has the code used in the patch.  And when I print out the tokenParams in /CRM/Core/BAO/ActionSchedule.php my summary token is there.
How can I trace and find out where it's going wrong?

The query which retrieves event info is assembled and executed around line 648 (in trunk version of ActionSchedule.php). So you could dump that $query variable, and run it in MySQL to see whether the 'summary' column has the expected data etc..

Code: [Select]
      $dao = CRM_Core_DAO::executeQuery($query,
        array(1 => array($actionSchedule->id, 'Integer'))
      );
Protect your investment in CiviCRM by  becoming a Member!

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • Event Reminder tokens

This forum was archived on 2017-11-26.