Drupal: Difference between revisions

From Elvanör's Technical Wiki
Jump to navigation Jump to search
(Created page with '= Themes = * You can have a separate theme for the front end and the back office, but by default the theme is used for both aspects. Go to Administer -> Site configuration -> Ad…')
 
No edit summary
Line 2: Line 2:


* You can have a separate theme for the front end and the back office, but by default the theme is used for both aspects. Go to Administer -> Site configuration -> Administration theme to configure this.
* You can have a separate theme for the front end and the back office, but by default the theme is used for both aspects. Go to Administer -> Site configuration -> Administration theme to configure this.
* When developping a theme, add the following function to your theme template.php file to flush the theme registry (apparently needed):
drupal_rebuild_theme_registry();
== Customizing modules ==
* Normally each module should register some theme hooks, which basically means that their output can be changed by themes (a default output should be provided as well). This can be done via a function (default) or the use of a template file. Some common registration are found in the common.inc file, for example a registration for the theme_links function.

Revision as of 17:09, 2 December 2010

Themes

  • You can have a separate theme for the front end and the back office, but by default the theme is used for both aspects. Go to Administer -> Site configuration -> Administration theme to configure this.
  • When developping a theme, add the following function to your theme template.php file to flush the theme registry (apparently needed):
drupal_rebuild_theme_registry();

Customizing modules

  • Normally each module should register some theme hooks, which basically means that their output can be changed by themes (a default output should be provided as well). This can be done via a function (default) or the use of a template file. Some common registration are found in the common.inc file, for example a registration for the theme_links function.