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) »
  • Discussion »
  • Extensions (Moderators: mathieu, totten, kasiawaka) »
  • Template used in more than one extension
Pages: [1]

Author Topic: Template used in more than one extension  (Read 908 times)

Erik Hommel

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1773
  • Karma: 59
    • EE-atWork
  • CiviCRM version: all sorts
  • CMS version: Drupal
  • MySQL version: Ubuntu's latest LTS version
  • PHP version: Ubuntu's latest LTS version
Template used in more than one extension
April 22, 2013, 11:18:11 am
What happens if a core template is customised, in more than one extension? Could we then have conflicting customizations? For example there is an addition to summary.tpl, and in another extension I want to introduce a new customization but also retain the one from the earlier one?
Or do we then fall back on the template customization folder rathervthan the templates folder in the extension?
Consultant/project manager at EEatWork and CiviCooP (http://www.civicoop.org/)

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Template used in more than one extension
April 22, 2013, 01:23:54 pm
It's going to cause problems, the way to inject stuff from the extension is not to override template files (or .extra.tpl)

They are ways to add content from extensions that are going to play better with other extensions. I like this one:

http://wiki.civicrm.org/confluence/display/CRMDOC42/Region+Reference

but for summary I'd rather use the hook_civicrm_summary directly eg.
https://github.com/TechToThePeople/rel4summary



X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Template used in more than one extension
April 22, 2013, 01:26:23 pm
Agree with X on that. As an application we've got to get away from such rigid templates.
Try asking your question on the new CiviCRM help site.

Erik Hommel

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1773
  • Karma: 59
    • EE-atWork
  • CiviCRM version: all sorts
  • CMS version: Drupal
  • MySQL version: Ubuntu's latest LTS version
  • PHP version: Ubuntu's latest LTS version
Re: Template used in more than one extension
April 23, 2013, 04:26:42 am
Totally agree on using the summary hooks, I was just using it as an example. Don't you think there could be / will be situations where a template is used in more than one extension? Is our advise to keep on using the customized templates in those situations, or to create one big extension containing all?
From a sharing point of view it would be best to create smaller extensions, but that increases the risk of conflicts?
Consultant/project manager at EEatWork and CiviCooP (http://www.civicoop.org/)

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Template used in more than one extension
April 23, 2013, 07:35:40 am
Not sure what to advise, except "hang in there until we get a more flexible templating system into core" It's definitely needed.
Try asking your question on the new CiviCRM help site.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Discussion »
  • Extensions (Moderators: mathieu, totten, kasiawaka) »
  • Template used in more than one extension

This forum was archived on 2017-11-26.