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) »
  • Membership token values don't display value in mailing
Pages: [1]

Author Topic: Membership token values don't display value in mailing  (Read 809 times)

skoehn

  • I’m new here
  • *
  • Posts: 14
  • Karma: 1
Membership token values don't display value in mailing
September 14, 2010, 09:36:42 am
I am running CiviCRM v. 3.2.2 on a Drupal 6.19 installation.

I have put together a mailing to send a membership card to new members that lists their name, member id (which I've just used the Contact ID for) and their expiration date.

I used
Code: [Select]
{$memberParams.end_date} for the expiration date, but nothing at all is displayed for expiration date when I send a test mailing. (It used to just display the token, and then I defined the smarty line in the settings file, and now it is blank.)

I have
Code: [Select]
define( 'CIVICRM_MAIL_SMARTY', 1 ); in my civicrm.settings.php file and
Code: [Select]
$memberParams = array( 'id'                 => $dao->membership_id,
                                   'status_id'          => $dao->status_id,
                                   'contact_id'         => $dao->contact_id,
                                   'membership_type_id' => $dao->membership_type_id,
                                   'membership_type'    => $allTypes[$dao->membership_type_id],
                                   'join_date'          => $dao->join_date,
                                   'start_date'         => $dao->start_date,
                                   'end_date'           => $dao->end_date,
                                   'reminder_date'      => $dao->reminder_date,
                                   'source'             => $dao->source,
                                   'skipStatusCal'      => true,
                                   'skipRecentView'     => true );
            
            $smarty->assign_by_ref('memberParams', $memberParams);
in my UpdateMembershipRecord.php file.

I'm not sure what I'm missing. Does anyone have any suggestions?

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: Membership token values don't display value in mailing
September 14, 2010, 02:00:45 pm

can u do a debug print on the $memberParams array in PHP and see if end_date does have a value?

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

2020media

  • I’m new here
  • *
  • Posts: 15
  • Karma: 0
    • 2020Media
Re: Membership token values don't display value in mailing
September 22, 2010, 02:31:32 am
Have you actually run UpdateMembershipRecord.php ?
CiviCRM Hosting: [http://www.2020media.com/civicrm]

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • Membership token values don't display value in mailing

This forum was archived on 2017-11-26.