|
This is implemented in 3.0, but you can backport it to 2.2 by copying the file CRM/Core/Smarty/plugins/function.civicrm_api.php For instance, you might want to display the related contacts from within a profile, or all her/his activities... Anything that can be accessed through the api can be displayed from any template. If you are familiar with civicrm api v2, it will be fairly straightforward to use. From anywhere within your template, simply call: * entity is the content you want to fetch, eg. "contact", "activity", "contribution"...
For instance, is you want to display a list of contacts The extra params allow to filter, for instance only the individual contacts in France, and return only the sort_name and the email. |
Labels