Aller directement à la fin des métadonnées
Aller au début des métadonnées


Documentation Search


CiviCRM 4.1 Documentation

Developer Resources


CiviCRM books!

Make sure to check out our Online User/Administrator and Developer Guides! You can also support this project by ordering a hard copy.

Or support us by buying an eBook or hard copy of Using CiviCRM from Packt Publishing.

The simpliest, and easiest, configuration on the badges is to change the background image (by default, it's a civicrm logo).

To do that, you simply have to set up a custom template directory, and add a logo (png format) in the directory templates/CRM/Event/Badge/CRM_Event_Badge_Logo.png or /CRM/Event/Badge/CRM_Event_Badge_NameTent.png (respectively for the Logo or name tent format).

You can also set a specific logo for a specific event by putting the logo into templates/CRM/Event/Badge/[event id]/[class name].png

eg for the Logo format of the event number 42, simply put the image  templates/CRM/Event/Badge/42/CRM_Event_Badge_Logo.png

You might want to create a new format, simply go to the admin (http://sandbox.civicrm.org/civicrm/admin/options/event_badge?group=event_badge&reset=1) and create a new event badge.

You will have to provide a class that formats each badge. For instance, the Logo template CRM/Event/Badge/Logo.php contains two methods: the constuctor, that mostly sets the format of the page (how many badges per page), and generateLabels, that format each label.

$participant contains the datas about the participant (name, oganization, role...)

If you create a new format, please share it with the community and add it as a sub page below.

In theory, you can use a jpg or gif format. It did work much better with png in my case, YMMV.

Étiquette
  • Aucun