1

I know that sticking in a contact-related custom field to the invoice template is just "contact.custom_xx" (where xx = custom field id).

We're trying to do the same for a Contribution-related custom field, but the syntax:

contribute.custom_xx or contribution.custom_xx is not working.

Any suggestions?

2 Answers 2

1

Tokens are available only for contact related columns - if you want to use contribution related columns as tokens then you need to create an extension and add token hooks for making the values available in tokens list

Please refer to the following link for creating token hooks

http://wiki.civicrm.org/confluence/display/CRMDOC/hook_civicrm_tokens

http://wiki.civicrm.org/confluence/display/CRMDOC/hook_civicrm_tokenValues

1

Also have a look at the answer to this more recent question about how to add custom Participant and Organisation fields to an invoice.

How to create tokens for custom fields (participant, individual, organisation)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.