[development] override theme of another module

Roman Chyla roman.chyla at gmail.com
Thu Sep 27 18:34:21 UTC 2007


Hi all,
I found only unanswered questions to my own question about how to
override theme function of an another module and not using phptemplate
eg.
http://lists.drupal.org/archives/themes/2007-07/msg00000.html
http://lists.drupal.org/archives/development/2007-04/msg00318.html

As my problem is basically similar, I would like to ask for
confirmation that it is not possible to easily override themeing of a
module.

In my own module (ejournal) user can set up many publications and
these publications should share the same code for the functionality,
yet not necessarily the same code for design. So far, the themeing
functions of the module can be overriden becase they are enclosed in
calls

if(!function_exists('theme_ejournal_issue')) {
  function theme_ejournal_issue()....
}

it is possible to override these themeing functions on a journal
basis, using chosen .inc files to be loaded, but lately i was thinking
if there is not an easier and more elegant way how to conditionally
override the module's themeing functions

Thanks for any answer, hint, confirmation etc.

  roman


More information about the development mailing list